Quick tip for string concatenation in Power Apps Canvas

Quick tip for string concatenation in Power Apps Canvas

We always need in our Power Apps applications to combine and add multiple string values so that we can display more data in one place.

While Power Apps Canvas does not have native support for string interpolation in the same way as some programming languages, you can achieve similar results using the Concatenate function or the “&” operator. Here are some examples of how this was done in the past.

The old way of connecting the strings and dynamic values:


Concatenate( "My name is", " ", User().FullName, " ", " and my email is: ", User().Email)

Adding text together with & operator:

"My name is" & " " & User().FullName & " " & " and my email is: " & User().Email

The new way of doing with string interpolation:

$"My name is {User().FullName} and my email is: {User().Email}"

You can see that now with the support of string interpolation code is shorter and easier to read, which is very important for the future maintenance of the applications for you or the person who will need to investigate this code after you.

I hope that this blog will help you and shorten your code writing inside of canvas applications.

Stay tuned for more tips and blogs soon!

Leave a Reply

Your email address will not be published. Required fields are marked *