web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Unneeded line breaks w...
Power Automate
Suggested Answer

Unneeded line breaks when copying text into excel

(1) ShareShare
ReportReport
Posted on by 76
Hi, 
 
I need to know how to stop line breaks being added when I copy text from an email into excel? 
 
I've got this function triming the text I want from the email: 
trim(first(split(last(split(trim(outputs('Html_to_text')?['body']), 'Report summary:')), 'Outcome:')))
 
When it enters into excel it creates random line breaks in to text:
 
I've blurred the actual text because it contained sensitive information but the cell on the top is where I've copied and pasted the text from the email manually and the one on the bottom was done using the formula above in power automate. I need it to stop adding those extra line breaks if possible. Any advice?
 
Thank you,
Lauren
Categories:
I have the same question (0)
  • Suggested answer
    trice602 Profile Picture
    15,404 Super User 2025 Season 2 on at
    Hi,
     
    One this you try after this expression is to replace '\n' with ''.
     
    ------------------------------------------------


    If this was helpful, please like and/or mark as a verified answer to help others find this too!


    Always glad to help! 💯💯💯💯💯

    Tom 

    Follow me on LinkedIn - Thomas Rice, PMP | LinkedIn

     


     
  • uartimin Profile Picture
    2 on at
    If you use "Convert HTML to Text" to remove the HTML tags, sometimes it will break it into several lines. It is difficult to remove HTML tags while keeping the original text format.
     
    See known issues and limitations.
     
    You can add a compose action to replace the "\n" with spacing. 
  • LB-20090315-0 Profile Picture
    76 on at
    Thank youuartimin andtrice602. I appreciate the suggestions. Sad to report neither attempts at using the replace function have successfully stopped the extra line breaks. I'm sure that's the way to go, I probably just need different inputs. 
     
    If anyone has any other ideas I could try please let me know! I'll be happy to experiment until I get this. 
     
    Many Thanks,
    Lauren
  • trice602 Profile Picture
    15,404 Super User 2025 Season 2 on at
    Hey there!
     
    I am following up on this post unneeded line breaks when copying text into excel in this category building flows from 11/24/2024.  I know the post is a little older, but it is a common question here so wanted to take a moment and follow-up. I see there have been 3 replies and 1 likes and asking if your question has been answered.  If so, please help the community out by completing one or more of the following actions!  Thanks in advance!
     
    Easy as 1-2-3 ‼️💯⭐😎🆒🙏
     
    1) Mark a reply as a verified answer - this is essential, and it helps others with the same general question find this thread. ✅
    2) You can also mark one of more replies as a verified answer.  Please take a moment and give the author credit for volunteering their time. ✌️
    3) Like one or more replies.  Kudos always greatly appreciated! 👍
     
    Pro tip:  if you found your own solution or workaround, feel free to add a reply to your own post and mark it as the solution too!  The goal is to get this thread marked with a verified answer by anyone that finds one or more replies helpful!
     
    Again, thanks in advance for reading and responding, always glad to help!  Tom 💯💯💯💯💯
  • trice602 Profile Picture
    15,404 Super User 2025 Season 2 on at
    If I can help with anything else please let me know or tag me in a future post, I enjoy reading and answering questions.  Always glad to help!  Tom 💯💯💯💯💯

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard