Click or drag to resize
MimeKit

HeaderGetValue(Encoding) Method

Get the header value using the specified character encoding.

Namespace: MimeKit
Assembly: MimeKit (in MimeKit.dll) Version: 4.7.1
Syntax
C#
public string GetValue(
	Encoding encoding
)

Parameters

encoding  Encoding
The character encoding to use as a fallback.

Return Value

String
The value.
Remarks

If the raw header value does not properly encode non-ASCII text, the decoder will fall back to a default charset encoding. Sometimes, however, this default charset fallback is wrong and the mail client may wish to override that default charset on a per-header basis.

By using this method, the client is able to override the fallback charset on a per-header basis.

See Also