I am taking sales order numbers from a variable(array) and I want to put these order numbers into new line in outlook mail body(HTML format)? if anybody can help?

Hi Team,

Delivery has been created for the orders 0311056152 0311059331.


give a try on String.Join("<br>",arrSONumbers)

in general with <br> a linebreak can be done in case of email body is in html format

1 Like

You can try this one to concatenate in your mail body

[quote=“sai_krishna_somisetty, post:5, topic:326890”]
String.Join(Environment.NewLine, arrayName)

Could you please tell like how can i shift each order number into new line?
As the logic you gave is giving this output?

It won’t work for HTML body format right?

Uncheck the “is body html” in your properties and try this

“Hi Team”+Environment.NewLine+Environment.NewLine+
"Delivery has been created for the orders "+Environment.NewLine+
“Attcahed screen shot for the reference.”


@ppr : could you please help on this?

isBodyHtml is activated:

String.Join will put the separator string between the items
<br> the the htnl Linebreak tag

isBodyHtml is not activated:

refering to your screenshot from above you also need to insert additional linebreaks for other parts of the body text e.g. before the orders number

we would suggest to use a text file as a template file and then do a dynamic replace on placeholders within the template

also have a look here on a different but close to the same main building blocks

it worked thank you so much for the help :slight_smile:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.