如何让邮件内容换行
以下代码除了 & ,其余都是原样显示,没有换行:
-------------------------
Dim WebmailMsg As String = "Full <br> Name: " & UserName & ControlChars.Cr & _
" <br /> \r \nUser Name: " & UserName & ControlChars.Cr & _
" <br /> \r \nUser Email: " & user_email & ControlChars.Cr & ControlChars.Cr & _
" <br /> \r\nTo confirm this registration, log on to UserMain page, activate the user, set the access right and send a confirmation to the user. If the user does not provide the salary info, please contact the user to obtain those neccessary info. " & ControlChars.Cr & ControlChars.Cr & _
" <br /> \r\nEmail sent via GearUp Match web interface. "
受到的邮件内容如下:
--------------------------------------
Full <br> Name: ert345 <br /> \r \nUser Name: ert345 <br /> \r \nUser
Email: sss@s33s.ss <br /> \r\nTo confirm this registration, log on to UserMain
page, activate the user, set the access right and send a confirmation to the user.
If the user does not provide the salary info, please contact the user to obtain those
neccessary info. <br /> \r\nEmail sent via GearUp Match web interface.
------解决方案--------------------mail.BodyFormat = MailFormat.Html
这样呀~~~
------解决方案--------------------换行:<br>