System.Net.Mail.MailMessage.BodyEncoding Property

Gets or sets the encoding used to encode the message body.

Syntax

public System.Text.Encoding BodyEncoding { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

The value specified for the MailMessage.BodyEncoding property sets the character set field in the Content-Type header. The default character set is "us-ascii".

If you set the MailMessage.BodyEncoding property to System.Text.Encoding.UTF8, System.Text.Encoding.Unicode, or System.Text.Encoding.UTF32, the Framework selects a System.Net.Mime.TransferEncoding of System.Net.Mime.TransferEncoding.Base64 for this System.Net.Mail.MailMessage.

Requirements

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