cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Responsive Resident
Responsive Resident

How do i create a variable for a new line multiple selection flow (picture of my flow)

Hi Guys,

 

Ive got a flow that i need help with, the data comes from a list with several multiple selections choice columns and i have the data going to an email, it works however the data has no spacing between selections, eg

 

for forum.png

id like for the data to have a line break and a minus (-) at the start of each line i.e

 

-intersection 1

-intersection 2

etc etc

 

 

Can you please help myself with the flow below

 

foummm.png

 

Any help would be appreciated, thankyou

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Re: How do i create a variable for a new line multiple selection flow (picture of my flow)

Hi @shaneOZ ,

 

To have a line break and a minus (-) at the start of each line, please try with the following flow configuration.

 

Initialize an Array Variable named as Test. Then an Apply to each action, which select value from the multiple selection enabled column, add action Append to array within the loop, and set Value with the dynamic content of the choice column value.

 

Under Apply to each, add Compose action with the following code:

join(variables('Test'),'-')

 

Add another Compose action with the following code:

concat('-',replace(outputs('Compose'),'-','</br>-'))

 

In the action send an email, select Compose output in the body field, and select Yes for the Is HTML field.

1.PNG2.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Community Support
Community Support

Re: How do i create a variable for a new line multiple selection flow (picture of my flow)

Hi @shaneOZ ,

 

To have a line break and a minus (-) at the start of each line, please try with the following flow configuration.

 

Initialize an Array Variable named as Test. Then an Apply to each action, which select value from the multiple selection enabled column, add action Append to array within the loop, and set Value with the dynamic content of the choice column value.

 

Under Apply to each, add Compose action with the following code:

join(variables('Test'),'-')

 

Add another Compose action with the following code:

concat('-',replace(outputs('Compose'),'-','</br>-'))

 

In the action send an email, select Compose output in the body field, and select Yes for the Is HTML field.

1.PNG2.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted
Responsive Resident
Responsive Resident

Re: How do i create a variable for a new line multiple selection flow (picture of my flow)


@v-yamao-msft wrote:

Hi @shaneOZ ,

 

To have a line break and a minus (-) at the start of each line, please try with the following flow configuration.

 

Initialize an Array Variable named as Test. Then an Apply to each action, which select value from the multiple selection enabled column, add action Append to array within the loop, and set Value with the dynamic content of the choice column value.

 

Under Apply to each, add Compose action with the following code:

join(variables('Test'),'-')

 

Add another Compose action with the following code:

concat('-',replace(outputs('Compose'),'-','</br>-'))

 

In the action send an email, select Compose output in the body field, and select Yes for the Is HTML field.

1.PNG2.PNG

 

Best regards,

Mabel

 


Thankyou again Mabel,

 

Ill mark as solved but before i do i take it there is no way to do this in the Email V2? and i have to write it body in Html? 

Highlighted
Community Support
Community Support

Re: How do i create a variable for a new line multiple selection flow (picture of my flow)

Hi @shaneOZ ,

 

Have you tested it on your side?

 

If it works for you, please mark it as Answer so that it can help others who have the same issue with you.

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
secondImage

August 2020 CYST Winners!

Check out the winners of the recent 'Can You Solve These?' community challenge!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

thirdimage

Power Automate Community User Group Member Badge

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

Top Solution Authors
Top Kudoed Authors
Users online (4,216)