Simplified Conversion of Outlook Messages to MIME Format with Aspose.Email for Java 16.11.0

Share on FacebookTweet about this on TwitterShare on LinkedIn

Aspose.Email for Java 16.11.0 has been released. Ported from its equivalent .NET version, this month’s release includes the same features, enhancements and bug fixes that were part of the .NET version of the API. Specifically, it enhances the functionality of Outlook MSG conversion to MIME message. For a detailed note on what is new and fixed, please visit our documentation section for release notes of this month’s version.

Enhancements

Outlook MSG conversion to MIME: This month’s release simplifies the conversion process of Outlook messages (MSG) to MIME. Instead of using the MailMessageInterpreter class, the API provides overloads of MapiMesasge class’s save method to save MSG file to EML. In addition, the MapiMessage class now exposes toMailMessage method that converts MSG files to EML with additional options. The following code sample shows the usage of this API functionality.

MapiMessage msg = new MapiMessage(
"sender@test.com", 
"recipient1@test.com; recipient2@test.com", 
"Test Subject", 
"This is a body of message.");
MailConversionOptions options = new MailConversionOptions();
options.setConvertAsTnef(true);
MailMessage mail = msg.toMailMessage(options);

ByteArrayOutputStream ms = new ByteArrayOutputStream();
msg.save(ms, SaveOptions.getDefaultHtml());

String fileName = "savedMessage.eml";
msg.save(fileName, SaveOptions.getDefaultEml());

Provision of BCC field in Exhcnage Message Summary Information: This month’s release also enhances the ExchangeMessageInfo class for retrieving BCC information from email messages. This is helpful in retrieving the information for email messages from mailbox’s Draft as well as Sent Items folder.

Other Improvements

This month’s release also fixes several bugs that further adds to the overall functional improvement of the API.

API Resources

We have detailed information available online for getting started with the Aspose.Email for Java API. These are: