MailBee.NET Objects 4.0

MailMessage.BodyHtmlText Property

Gets or sets the HTML body of the message.

public string BodyHtmlText {get; set;}

Property Value

A string containing the HTML body of the message, or an empty string if the message does not have an HTML body.

Remarks

If the mail message doesn't contain HTML-formatted body and it's desired to get it from plain text, you should set MailMessage.Parser.PlainToHtmlMode to IfNoHtml value. MailBee will generate HTML body automatically and you can then get it from BodyHtmlText property as usually.

Note   MailMessage.Parser.PlainToHtmlMode should be set before any property of MailMessage object gets accessed and the message gets parsed. If message was already parsed, you will have to call MailMessage.Parser.Apply method to reparse it.

Example

The example is available in MailMessage topic.

See Also

MailMessage Class | MailBee.Mime Namespace | BodyPlainText