Browse our Products

Aspose.Email for .NET 21.10 Release Notes

All Changes

KeySummaryCategory
EMAILNET-40441Add support for saving appointments to MSG formatFeature
EMAILNET-40449MSG file body with emoji is changed after Load/SaveEnhancement
EMAILNET-40440Optional attendees are not displayed in the mht header outputEnhancement
EMAILNET-40446Incorrect ClientSubmitTime when converting EML to MSGBug
EMAILNET-40455EmlLoadOptions.PrefferedTextEncoding option works differently for different EML filesBug
EMAILNET-40436New unique custom message flags are detected as existingBug
EMAILNET-40425Event appears only in one day, but should repeat every yearBug

New Features

Saving appointments to MSG format

It’s now possible to save appointments directly to .msg files. The following public classes have been added to the API:

  • AppointmentMsgSaveOptions

    class with additional options to save appointments in msg format.

  • AppointmentIcsSaveOptions

    class with additional options to save appointment in ics format. It was added to replace the obsolete IcsSaveOptions.

Code example

var appointment = Appointment.Load(fileName);
appointment.Save(fileName + ".ics", new AppointmentIcsSaveOptions());
appointment.Save(fileName + ".msg", new AppointmentMsgSaveOptions(););

Preserving RTF body when converting MapiMessage to MailMesage

Changes in public API

  • MsgLoadOptions.PreserveRtfContent

    Gets or sets a value indicating whether to keep the rtf body in MailMessage.

  • MailConversionOptions.PreserveRtfContent

    Gets or sets a value indicating whether to keep the rtf body in MailMessage.

Code example

var appointment = Appointment.Load(fileName);
appointment.Save(fileName + ".ics", new AppointmentIcsSaveOptions());
appointment.Save(fileName + ".msg", new AppointmentMsgSaveOptions(););

Displaying the optional attendees in the mht header output

Changes in public API

  • MhtTemplateName.OptionalAttendees

    Optional attendees header name.

Code example

MhtSaveOptions options = new MhtSaveOptions()
{
    MhtFormatOptions = MhtFormatOptions.RenderCalendarEvent | MhtFormatOptions.WriteHeader
};

MapiMessage msg = MapiMessage.Load(fileName);
msg.Save(fileName + ".mhtml", options);

//if you need to skip OptionalAttendees in mhtml file you can clear format template for OptionalAttendees
options.FormatTemplates[MhtTemplateName.OptionalAttendees] = "";
msg.Save(fileName + "2.mhtml", options);