MapiMessage.Load

Load(string)

Loads message from file.

public static MapiMessage Load(string fileName)
ParameterTypeDescription
fileNameStringSource file pathString.

Exceptions

exceptioncondition
ArgumentNullExceptionFile name should not be null or empty.
NotSupportedExceptionStream does not support reading.
FormatNotSupportedExceptionPassed message format is not supported.

See Also


Load(Stream)

Loads message from stream.

public static MapiMessage Load(Stream stream)
ParameterTypeDescription
streamStreamSource streamStream.

Exceptions

exceptioncondition
FormatNotSupportedExceptionPassed message format is not supported.
ArgumentNullExceptionStream should not be null or empty.
NotSupportedExceptionStream does not support reading.

See Also


Load(Stream, LoadOptions)

Loads message from stream with additional options.

public static MapiMessage Load(Stream stream, LoadOptions options)
ParameterTypeDescription
streamStreamSource streamStream.
optionsLoadOptionsAdditional options LoadOptions.

Exceptions

exceptioncondition
FormatNotSupportedExceptionPassed message format is not supported.
ArgumentNullExceptionStream should not be null or empty.
NotSupportedExceptionStream does not support reading.

See Also


Load(string, LoadOptions)

Loads message from file with additional options.

public static MapiMessage Load(string fileName, LoadOptions options)
ParameterTypeDescription
fileNameStringSource file pathString.
optionsLoadOptionsAdditional options LoadOptions.

Exceptions

exceptioncondition
ArgumentNullExceptionFile name should not be null or empty.
NotSupportedExceptionStream does not support reading.
FormatNotSupportedExceptionPassed message format is not supported.

See Also