MailBee. NET Objects Tutorials

Display HTML/plain text message in desktop application

If you need to display the HTML message in plain-text control (like Memo) in the desktop application, you should convert HTML text body into plain-text.

C#

msg.Parser.HtmlToPlainMode = HtmlToPlainAutoConvert.IfNoPlain;

VB.NET

msg.Parser.HtmlToPlainMode = HtmlToPlainAutoConvert.IfNoPlain

The code above converts the message to plain-text if it does not already have the plain-text body. You can then display plain-text body as below (assuming textBox1 is a text control on the form):

C#

textBox1.Text += msg.BodyPlainText;

VB.NET

textBox1.Text += msg.BodyPlainText