Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Using Flows
Answered

How to create a space between text rows in flow email

(0) ShareShare
ReportReport
Posted on by 119

Hi all

 

In my sharepoint list I have a column called Work Log Details, the Work Log Details is updated from a Power App.  A user submits a comment in the PowerApp and it is added to the top of the Work Log Details in Sharepoint, it appears like this in Sharepoint with the most recent comment at the top.

 

Edit Comment [Date: October 27, 2022 3:57 PM; User: ######]
Testing

 

Edit Comment [Date: October 27, 2022 3:56 PM; User: ######]
Testing

 

Edit Comment [Date: 10/26/2022 4:53 PM; User: ######]
edit 50000

 

My flow is setup thike this:

 

Alison1_0-1666929126729.png

Get changes for an item Expression: add(int(triggerOutputs()?['body/{VersionNumber}']),-1)

Condition: Has Column Changed: Work Log Details

Alison1_1-1666929289630.png

 

The problem is, the Work Log Details appear like this in the email without spaces as per the Sharepoint list and PowerApp. Does anyone know how I can fix please please?

 

Alison1_2-1666929584343.png

 

Thank you

 

 

 

 

 

  • Alison1 Profile Picture
    119 on at
    Re: How to create a space between text rows in flow email

    Thank you @Expiscornovus, perfect 🙂

  • AbdulWahab Profile Picture
    517 on at
    Re: How to create a space between text rows in flow email

    Hi @Expiscornovus ,

     

    Got it.

     

    Thanks
    Regards,

     

    Abdul Wahab
    Power Platform & Customer Engagement Developer/Lead/Solution Architecture/Project Manager
    Direct/WhatsApp:+923323281237
    E-mail: abdulwahabubit@outlook.com
    Skype: abdul.wahabubit
    Linkedin: https://www.linkedin.com/in/abdul-wahab-a5b8b011a/

  • Expiscornovus Profile Picture
    31,643 Most Valuable Professional on at
    Re: How to create a space between text rows in flow email

    Hi @AbdulWahab,

     

    Like mentioned in my previous reply, when splitting on 0A the details of the user and the actual comment text itself would be in separate items of the array.

     

    When you use the first you would only get the first item which would be the text 

    Edit Comment [Date: October 27, 2022 3:57 PM; User: ######] without the comment text Testing which is located in the 2nd item.

     

    That's why I was suggesting to use a take and collect the first two items instead of a first one 😉

     

    twoitems.png

     

     

     

     

  • AbdulWahab Profile Picture
    517 on at
    Re: How to create a space between text rows in flow email

    Hi @Expiscornovus & @Alison1 

     

    What about the first function? For more details: Power Automate Fundamentals # 48: Usage of First &... - Power Platform Community (microsoft.com)

     

     

    If I have answered your question, please mark your post as Solved.

     

    If you like my response, please give it a Thumbs Up.

     

    Let me know if I can provide you with more details.

     

    Thanks
    Regards,

     

    Abdul Wahab
    Power Platform & Customer Engagement Developer/Lead/Solution Architecture/Project Manager
    Direct/WhatsApp:+923323281237
    E-mail: abdulwahabubit@outlook.com
    Skype: abdul.wahabubit
    Linkedin: https://www.linkedin.com/in/abdul-wahab-a5b8b011a/

  • Verified answer
    Expiscornovus Profile Picture
    31,643 Most Valuable Professional on at
    Re: How to create a space between text rows in flow email

    Hi @Alison1,

     

    If you only want the newly added comment you will need the first two lines (the details of the user and the comment itself). You can use a take function for that.

     

    join(array(take(split(triggerOutputs()?['body/WorkLogDetails'], decodeUriComponent('%0A')), 2)), '<br>')

     

  • Alison1 Profile Picture
    119 on at
    Re: How to create a space between text rows in flow email

    Hi @Expiscornovus 

    That works perfectly thank you so much! Do you know if there is a way to just include the newly added comment?

    Thanks

    Alison

  • Expiscornovus Profile Picture
    31,643 Most Valuable Professional on at
    Re: How to create a space between text rows in flow email

    Hi All,

     

    I think the challenge with this is that mark-up is not carried over from the field value and not in the body of the Send email itself.

     

    I would suggest to use an expression for this. Split the Work Log Details field value on the new line character (0A) and join it back together with a br HTML tag.

     

    Below is an example of that approach, can you try that?

    join(split(triggerOutputs()?['body/WorkLogDetails'], decodeUriComponent('%0A')), '<br>')

     

    join_brtag.png

     

     

  • RobElliott Profile Picture
    10,118 Super User 2025 Season 1 on at
    Re: How to create a space between text rows in flow email

    @Alison1 click the code view button </> then add <br> tags. You can also add other tags like bold, underline, tables etc etc

     

    Rob
    Los Gallardos
    If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.

  • AbdulWahab Profile Picture
    517 on at
    Re: How to create a space between text rows in flow email

    Hi @Alison1 ,

     

    What about <br> tag. Did you try to add it?

     

    If I have answered your question, please mark your post as Solved.

     

    If you like my response, please give it a Thumbs Up.

     

    Let me know if I can provide you with more details.

     

    Thanks
    Regards,

     

    Abdul Wahab
    Power Platform & Customer Engagement Developer/Lead/Solution Architecture/Project Manager
    Direct/WhatsApp:+923323281237
    E-mail: abdulwahabubit@outlook.com
    Skype: abdul.wahabubit
    Linkedin: https://www.linkedin.com/in/abdul-wahab-a5b8b011a/

     

  • Alison1 Profile Picture
    119 on at
    Re: How to create a space between text rows in flow email

    Hi @AbdulWahab 

     

    Yes that would work.

     

    Thanks

    Alison

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,668 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,004 Most Valuable Professional

Leaderboard

Featured topics

Restore a deleted flow