SmtpBodyHtmlText Property
Gets or sets HTML version of the message body.

Namespace: MailBee.SmtpMail
Assembly: MailBee.NET (in MailBee.NET.dll) Version: 12.2.0 build 630 for .NET 4.5
public string BodyHtmlText { get; set; }

Property Value

Type: String
A string containing the message body as HTML.

This property is equivalent to BodyHtmlText property of Message object.

The developer can import HTML content (and, optionally, linked images, style-sheets, etc) from an HTML file or a web page using LoadBodyText(String, MessageBodyType, Encoding, ImportBodyOptions) method of Message object.

Specifying HTML body of the message.
// To use the code below, import MailBee namespaces at the top of your code.
using MailBee;
using MailBee.SmtpMail;
using MailBee.Mime;

// The actual code (put it into a method of your class)

Smtp mailer = new Smtp();

// Specify HTML body using multi-line string constant.
mailer.BodyHtmlText = @"<html>
<head><title>Page title</title></head>
<body>The text of the message. The next word is in <b>bold</b>.</body>;
See Also