cancel
Showing results for 
Search instead for 
Did you mean: 

Remove HTML tags from mail body

Hi,
I need to be able to remove the HTML tags from the main body of an email. I just need the content as a text.
Anyone knows how to do this? 

Thanks!
3 REPLIES 3

ewilson
Staff
Staff
@Evangelina Curró,

You could accomplish something like this using RegEx (Regular Expressions). You could use an expression similar to below to replace HTML tags with an empty string. You'd have to do this via a Code stage.
output = Regex.Replace(input, "<[a-zA-Z/].*?>", String.Empty);


Example set up of a Code stage
37045.png
37046.png
37047.png
Cheers,
Eric

MichealCharron
Level 7
@Evangelina Curró

You could use the "Regex Replace" action in the BP "Utility - Strings" VBO. The pattern I would use for it is "<[^>]*?>".

37048.png


Micheal Charron
RBC
Toronto, Ontario
Canada

It Works! Thank you so much!! @ewilson @MichealCharron  ​​