MapiCalendar.Save

Save(string, MapiCalendarSaveOptions)

Saves the calendar item to a file with the specified options.

public void Save(string filePath, MapiCalendarSaveOptions saveOptions)
ParameterTypeDescription
filePathStringThe path of the file to write.
saveOptionsMapiCalendarSaveOptionsThe options; they also select the format: MapiCalendarIcsSaveOptions for iCalendar, MapiCalendarMsgSaveOptions for MSG.

Exceptions

exceptioncondition
ArgumentExceptionfilePath is null or empty.
NotSupportedExceptionThe format of saveOptions is not supported.

See Also


Save(Stream, MapiCalendarSaveOptions)

Saves the calendar item to a stream with the specified options.

public void Save(Stream stream, MapiCalendarSaveOptions saveOptions)
ParameterTypeDescription
streamStreamThe stream to write to.
saveOptionsMapiCalendarSaveOptionsThe options; they also select the format: MapiCalendarIcsSaveOptions for iCalendar, MapiCalendarMsgSaveOptions for MSG.

Exceptions

exceptioncondition
ArgumentNullExceptionstream or saveOptions is null.
NotSupportedExceptionThe format of saveOptions is not supported.
NotSupportedExceptionstream does not support writing.

See Also


Save(string)

Saves the calendar item to an iCalendar (.ics) file with the default options.

public void Save(string filePath)
ParameterTypeDescription
filePathStringThe path of the file to write.

Exceptions

exceptioncondition
ArgumentExceptionfilePath is null or empty.

See Also


Save(string, AppointmentSaveFormat)

Saves the calendar item to a file in the specified format with the default options.

public void Save(string filePath, AppointmentSaveFormat saveFormat)
ParameterTypeDescription
filePathStringThe path of the file to write.
saveFormatAppointmentSaveFormatThe format: ICS or MSG.

Exceptions

exceptioncondition
ArgumentExceptionfilePath is null or empty.
NotSupportedExceptionsaveFormat is not supported.

See Also


Save(Stream)

Saves the calendar item to a stream in iCalendar format with the default options.

public void Save(Stream stream)
ParameterTypeDescription
streamStreamThe stream to write to.

Exceptions

exceptioncondition
ArgumentNullExceptionstream is null.
NotSupportedExceptionstream does not support writing.

See Also


Save(Stream, AppointmentSaveFormat)

Saves the calendar item to a stream in the specified format with the default options.

public void Save(Stream stream, AppointmentSaveFormat saveFormat)
ParameterTypeDescription
streamStreamThe stream to write to.
saveFormatAppointmentSaveFormatThe format: ICS or MSG.

Exceptions

exceptioncondition
ArgumentNullExceptionstream is null.
NotSupportedExceptionsaveFormat is not supported.
NotSupportedExceptionstream does not support writing.

See Also