I didn’t observe this situation until now but I can’t figure out how to solve it.
I will explain the issue with an exemple:
I will store into variable “test_String” the following string “Hello”+Environment.NewLine+“Thanks”.
I want to use this variable into a Body mail. When I send the email, that Environment.NewLine is not read and the mail body will be: “Hello,Thanks” and not
“Hello,
Thanks”
Same scenario if I want to use a Type into to add the contect of “test_String” into a field.
How can I solve this issue to display the content of a custom string variable?
while dealing with scenarios like that in email body environment.new line does not work in such scenarios you have to use html tags to give a line break where you want .
Just ad an html element to break your line in the variable where you stored the data and it will work.
I am still using Environment.NewLine in the mail body and if I set IsHTML only for my variable will not help because I will broke the rest of the body.
If I’m using Environment.NewLine in the mail body and if I set IsHTML only for my variable to work, will not help, because I will broke the rest of the body.
Just make another variable for the parts you want to use as an html , describe that variables with the value you want and then pass those variables in your existing mail body .
I’m not sure If I understood well.
If I store into a variable “Hello,”+“ ”+“Thanks” and I will not check IsBodyHtml (because I have already used in the body Environment.NewLine) the display text will be “Hello, Thanks”.
By the way, I have just retested my issue with the mail and it worked with Environment.NewLine in the variable. I don’t know what is wrong with the cases when it didn’t work…