MapiNote.SaveAsync

SaveAsync(Stream, NoteSaveFormat, CancellationToken)

Saves this MapiNote to the given stream using specified format asynchronously. The supported save format is MSG.

public Task SaveAsync(Stream stream, NoteSaveFormat saveFormat, CancellationToken token = default)
ParameterTypeDescription
streamStreamA stream to save to.
saveFormatNoteSaveFormatA save format.
tokenCancellationTokenPropagates notification that operations should be canceled.

Exceptions

exceptioncondition
ArgumentNullExceptionstream is null.
NotSupportedExceptionstream does not support writing.
NotSupportedExceptionThe specified format is not supported.

See Also


SaveAsync(string, NoteSaveFormat, CancellationToken)

Saves this MapiNote into file using specified format asynchronously. The supported save format is MSG.

public Task SaveAsync(string filePath, NoteSaveFormat saveFormat, CancellationToken token = default)
ParameterTypeDescription
filePathStringA file name.
saveFormatNoteSaveFormatA save format.
tokenCancellationTokenPropagates notification that operations should be canceled.

Exceptions

exceptioncondition
ArgumentExceptionfilePath is null or empty.
NotSupportedExceptionsome save option is not supported

See Also