Email Body Structure

hi all,

I am using “Send SMTP Mail Message” for sending the email, body of the email I requires is

"Hi All

Application is already Opened on VDI:"+Current_user.ToString+"Please close Application and try running 
again

Note: This is an Auto Generated Email. Please don't reply to this Mail as this mailbox is not 
monitored. In case of any queries, please reach out to RPA Team.

Thanks & Regards
RPA Team"

In this text the User Name is the Machine Name, but when trying to compile getting the below error
image
Please suggest me if, I am missing any Text Formatting.

Any suggestions will be helpful
Thanks in advance

Hi @harsha8687

Try like this
Hi All”+Environment.newline+" Application is already Opened on VDI:"+Current_User.ToString+"Please close Application and try running
again
"+Environment.NewLine+“Note: This is an Auto Generated Email. Please don’t reply to this Mail as this mailbox is not
monitored. In case of any queries, please reach out to RPA Team.”+Environment.Newline+Environment.Newline+“Thanks & Regards”+Environment.NewLine+“RPA Team”

Check this

Thanks
Ashwin S

Hi @harsha8687

You can also use this on Send SMTP Mail Message Body:

"<p><span Class=""hljs-string"">Hi </span><span Class=""hljs-string"">All</span></p><p><span Class=""hljs-String""> Application Is already Opened On VDI:""</span>"+Current_user.ToString+"<span class=""hljs-String"">""Please close Application And Try running again </span></p><p><span Class=""hljs-string"">Note: This Is an Auto Generated Email. Please don't reply to this Mail as this mailbox is not monitored. In case of any queries, please reach out to RPA Team. </span></p><p><span Class=""hljs-string"">Thanks &amp; Regards</span></p><p><span Class=""hljs-string""> RPA Team</span></p>"

And mark on SMTP Properties: isBodyHtml

1 Like

hi @Dragos_Padurariu1

Thanks a lot… it has worked for me

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