We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Issues in attachments when saving MailMessage


I have a MailMessage with an embedded attachment in it. That embedded attachment has some other attachments in it.
While saving this message using below code, instead of having 1 .msg attachment, it has 1 .txt and 1 .htm attachments.

mailMessage.Save(filePath, new EmlSaveOptions(MailMessageSaveType.EmlFormat) { PreserveEmbeddedMessageFormat = true });

Is this an issue, or there is a workaround for this.

Below I will attach the corrupted message example.
613715_corrupted.zip (7.0 MB)


We have logged this problem in our issue tracking system as EMAILNET-40561. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.


I see the issue is resolved, will it be included in next update?


It is to inform you that we have closed the issue EMAILNET-40561 with “Won’t Fix” resolution.

Please do not use MapiMessage when working with .eml message files. In this case, errors are possible as a result of double conversion of MSG-EML formats due to format differences.

Please use the latest version of Aspose.Email for .NET 22.2.0 with following code example.

var mailMessage = MailMessage.Load(MyDir + @"613715_corrupted.eml");
mailMessage.Save(MyDir + "out.eml", new EmlSaveOptions(MailMessageSaveType.EmlFormat) { PreserveEmbeddedMessageFormat = true });