Announcements
Hi is it possible to keep H3, br and Color tags after converting html to Text?
Once its converted I use the following expression to display the converted text:
replace(body('Html_to_text'), decodeuricomponent('%0A'), '')
Is this possible?
Hey @knishal
Maybe just use replace to remove everything, other than the above mentioned tags. And dont use html to text action.
Possible to provide an example?
@knishal
Can you give an example of your data, like if some name is there just write abc instead. Then I will give you the expression for it.
"<p><div class=\"ExternalClass4826EE5083FE4CE5AAC7B60172F68133\"><p>​This is a long text field Test<br></p></div></p>"
Above is an example of the Raw Input
This is more complex example: also there will be emails and links.
<p><div class=\"ExternalClassF3C98F93FC8A4A7D943D998FFA9D2819\"><p>Breakfast  <br></p><div> Text </div><div><br></div><div>More text​<br></div><p><br></p></div></p>"
Any help? @Sundeep_Malik
Way out of my league. ;(
@Paulie78Might be able to help.
Thank you Sundeep. @Paulie78
@Expiscornovus Any help will be greatly appreciated
Hi @knishal,
The issue is that this RTE type of field adds classes to divs and other kind of tags which the SharePoint page does not like. You could use a replace function in a loop to clean-up the mark-up.
In this thread I have shared an approach for that:
https://powerusers.microsoft.com/t5/Building-Flows/Send-an-HTTP-Request-to-Sharepoint/m-p/1811447/highlight/true#M199930
The first idea that comes to mind is to break the tags via find and replace prior to running it through the HTML to text. Try replacing '<h3' with '~H3~' you might have to do it on the closing tag as well. I don't know for certain what the HTML to text does, but my guess is it's a collection of regex find and replace statements that removes all the HTML tags.
If you have SQL you could probably find a similar collect of regex that you could tweak to make your own HTML to text, or office type scripts is another possible idea
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.
Congratulations to our 2026 Super Users!
Congratulations to our 2025 community superstars!
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Vish WR 784
Valantis 581
Haque 545