ValidateMessage

MailMessage.ValidateMessage method (1 of 2)

Validate eml message for corresponding to mime specification.

public static EmlValidationErrorCollection ValidateMessage(string fileName)
Parameter Type Description
fileName String A file name (eml).

Return Value

A EmlValidationErrorCollection containing the found validation error messages.

Exceptions

exception condition
ArgumentException fileName is null or empty.
FileNotFoundException The specified fileName doesn’t exist.

See Also


MailMessage.ValidateMessage method (2 of 2)

Validate eml message for corresponding to mime specification.

public static EmlValidationErrorCollection ValidateMessage(Stream stream)
Parameter Type Description
stream Stream A stream containing the message in eml format.

Return Value

A EmlValidationErrorCollection containing the found validation error messages.

Exceptions

exception condition
ArgumentNullException stream is null.

See Also