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

Free Support Forum - aspose.com

Embedded images in e-mails handled as attachments


we use the EWSClient of Aspose.Email to fetch e-mails from an exchange server and hand those over to a PDF converter application.
Now, when gathering EML files from the exchange server, the output PDF has embedded images as attachments. We contacted the developer of the PDF converter about this and they replied, that the structure of the EML file (fetched and saved with Aspose.Email) is not in the right format. The EML file does contain those image tags inside the EML, but it is not specified whether these are attachments or embedded images in the mail body. In this case, they are just handling the images as attachments.

This problem only started to occur when we updated to Aspose.Email Previously we used Aspose.Email and the PDF conversion was working without any problems.
Did you change the structure of EML files between those two versions?

One thing to remark is, that we tried to fetch e-mails from the Exchange server with the EWSClient with the method call “FetchMessage” which returned a MailMessage object. When changing the mehtod call to “FetchItem” for testing purposes, which returns a MapiMessage object, the EML strcutre seemed to be correct again and the PDF converter worked just fine with Aspose.Email

Was the method call “FetchMessage” just the wrong one and we should always call “FetchItem”? Or whats the difference in general between MailMessage and MapiMessage?

Thank you for you help!


I have observed the information shared by you and request you to please first try using latest Aspose.Email 19.1 on your end. If there is still an issue then please share the working sample project along with source files and generated PDF from previously used correct version that you feel right and output from latest versions. We will be able to investigate the issue further on our end on provision of requested information.