System.Net.Mail.MailMessage.Body Property

Gets or sets the message body.


public string Body { get; set; }


Documentation for this section has not yet been entered.


The System.Net.Mime.ContentType of the MailMessage.Body content is "text/plain". Specify the encoding used for the body with the MailMessage.BodyEncoding property.

If the body content is available in alternative formats that provide richer presentation options for the recipients, you can specify alternate views for the body content by using the MailMessage.AlternateViews property. For example, an application might choose to send both the plain text body and an HTML version of the message body. E-mail readers that can display HTML can present the HTML version of the body to the recipient, while readers that cannot display HTML will display the plain text version of the message instead.


Namespace: System.Net.Mail
Assembly: System (in System.dll)
Assembly Versions:,
Since: .NET 2.0