Skip to main content
August 13, 2021
Question

Send E-mail smart service and New Line Breaks

  • August 13, 2021
  • 3 replies
  • 2 views

Hi,

I am using the send email smart service.

I let the user write the body of the email in a paragraph field, save body text in a text variable, and in setup>Message Body field, I use an expression to fill the body with the text variable. 

However, the email gets sent with no formatting. At least, I want to capture the "new line" breaks that the user enters in the paragraph field.

I would appreciate your help.

    3 replies

    danny.verb
    August 13, 2021

    This can be tough. Something easy you can do is make an HTML template where you can inject your paragraph, this way you fully control the formatting.

    stefanhelzle0001
    Brainy
    August 13, 2021

    That text in the email is being HTML formatted. Replacing char(10) with "<br />" using substitute() should get you started.

    For more control on formatting, follow Danny's advice.

    August 13, 2021

    Thank you Danny and Stefan, the substitute solution worked like a charm!

    PS: The body in the Send E-Mail smart service can interpret html tags, so there was no need to use an html template.