For MimeMessage object

Applies to

MimeMessage object

Description

Sets the encoding of this email message body. The default encoding is UTF-8.

Data type

String.

Usage

In scripts

The Encoding property takes a string value.

The following example sets the Encoding property as UTF-8:

ismtp_email.message.Encoding = "UTF-8"

The following example sets the Encoding property as Windows-1252 (Western European):

ismtp_email.message.Encoding = "Windows-1252"

The following example sets the Encoding property as gb2312(Chinese Simplified):

ismtp_email.message.Encoding = "gb2312"