cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Perumal
Level 10

String concatenate with new line

I am trying to concatenate set of Text values with new line in between. I can't find way to add new line, tried "\n", which does not works. I am using Concatenate function.

1 ACCEPTED SOLUTION

Accepted Solutions
hpkeong
Level 10

Re: String concatenate with new line

Hi

 

I have a series of Useful Features of PowerApps, and I remember it is No. 12, explain about how to use:

- Collection + Concatenate + Concate...to email with html format.

 

Hope it helps.

 

https://powerusers.microsoft.com/t5/PowerApps-Forum/Useful-Features-of-PowerApps-12-Email-amp-Concat...

 

The results from my Shopping Apps is sent to out with results as follow (this is actual results).

 

Capture.PNGActual email received

 

Hope this really helps.

(I spent weeks on this and wish it is what you want as no guidance in LEARN Tutorial)

hpkeong

View solution in original post

13 REPLIES 13
hpkeong
Level 10

Re: String concatenate with new line

Hi

 

Would you consider using html textbox?

Although html5 is not fully supported (e.g.: Table is OK, but border not supported), most of the html5 syntax can be used in PowerApps.

 

Screenshot (251).png

hpkeong
Perumal
Level 10

Re: String concatenate with new line

Thanks for your suggestion.

 

My case:

---------------

I have a screen with set of TextInput boxes. On button click, I want to send a mail with values entered in the input boxes. In the mail, each value should be on a new line.

hpkeong
Level 10

Re: String concatenate with new line

Hi

 

I have a series of Useful Features of PowerApps, and I remember it is No. 12, explain about how to use:

- Collection + Concatenate + Concate...to email with html format.

 

Hope it helps.

 

https://powerusers.microsoft.com/t5/PowerApps-Forum/Useful-Features-of-PowerApps-12-Email-amp-Concat...

 

The results from my Shopping Apps is sent to out with results as follow (this is actual results).

 

Capture.PNGActual email received

 

Hope this really helps.

(I spent weeks on this and wish it is what you want as no guidance in LEARN Tutorial)

hpkeong

View solution in original post

Perumal
Level 10

Re: String concatenate with new line

Okay, I can understand there is no direct way to a add concatenate new line with strings, we need to use a hidden HTML text control. 

 

Thanks for your solution.

Highlighted
Power Apps Staff davidni
Power Apps Staff

Re: String concatenate with new line

Hi Perumal,

 

You can add a new line by using Ctrl+Enter in the formula bar, and new lines are perfectly valid withing quoted strings. Type the following formula for example:

"Hello" & "

" & "world"

 

Notice how there is a line break within the quotes.

David Nissimoff [MSFT] ** PowerApps Staff
Perumal
Level 10

Re: String concatenate with new line

Thanks @davidni, I will try it.

Power Apps Staff rgruian
Power Apps Staff

Re: String concatenate with new line

Even though this post accepted a solution, for the record please note that you can append newline (CR) characters to any string.

 

    "new" & Char(13) & "line"

 

or:

   

    "new" & "

    " & "line"

 

If you need CRLF sequences instead, please use Char(13) & Char(10).

 

 

Radu Gruian [MSFT] ** PowerApps Staff
Microsoft michowl
Microsoft

Re: String concatenate with new line

I'm finding that when I use the newline in the text box

 

"My title

Has 2 lines"

 

It looks correct initially. But when I preview the app or reopen the app, the line break remains in the fx field, but visually, the linebreak has been removed entirely.

 

Visual representation:

My titleHas 2 lines

Mordikus
Level: Powered On

Re: String concatenate with new line

Hello hpkeong,

 

which app are you using in this screenshot ?

 

Thanks and have a nice day !

 

Screenshot (251).png

Helpful resources

Announcements
Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Join THE global Microsoft Power Platform event series

Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

thirdimage

Microsoft Business Applications Virtual Launch

Join us for the Microsoft Business Applications Virtual Launch Event on Thursday, April 2, 2020, at 8:00 AM PST.

thirdimage

Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (10,008)