I am currently trying to reply to certain emails using the Reply Outlook mail activity. I am having trouble with the formatting. I am using an asset to store the body of the reply, initially I tried putting #'s in the asset text and using string.replace(“#”, vbnewline) the log message shows it formatted correctly, but when the actual email is sent, there are no new lines but the hashtags are removed.
Then I tried skipping the asset stage and actually writing the message into the body using environment.newline to seperate where I want the new lines to be, but that didn’t work either.
so I wouldn’t use the assets for this method would I? I would prefer to not have to hardcode this into the process, would this work in the config file?
of course you can do it with assets or with a config - as you wish!
You can just insert the HTML-Tags <br> and <p> into the string (asset/config/hardcoded doesn’t matter). Just remember to set the IsHtmlBody property of the mail activity to true (check box).
when you pass HTML text to the mail body’s variable as part of the Reply to Outlook Mail Message activity, it is formatted correctly, even though there isn’t an option for ‘IsBodyHTML’.
I’m ususally using the Send Outlook Mail Message activity and assumed the Reply activity had the same property. Thanks @ghazanfar for the additional info
So passing the text through I get this response in the logs:
it doesn’t seem to separate, do I have to change it from being a string? To some kind of HTML type or can the HTML text not be inside quotations?
Looks fine! The tags are a part of the string. It is the job of the mail service (Outlook) to transform this string into a proper mail body by processing the HTML tags.