Problem description:
We tried to convert saved msg messages to html and encountered problem with images in them. For other formats when “No Embedding” is selected images are saved as separate files next to html, however in case of Aspose.Email they are simply skipped.
String source = "e:/tmp/test.msg";
String destination = "e:/tmp/html.html";
Path p = Paths.get(source);
FileInputStream in = new FileInputStream(p.toFile());
LoadOptions loadOptions = new MsgLoadOptions();
loadOptions.setPrefferedTextEncoding(Charset.forName("UTF-8"));
MailMessage copyMail = MailMessage.load(in, loadOptions);
HtmlSaveOptions saveOptions = new HtmlSaveOptions();
saveOptions.setEmbedResources(false);<a class="attachment" href="/uploads/default/1201">Test.zip</a> (19.1 KB)
File file = Paths.get(destination).toFile();
copyMail.save(file.getAbsolutePath(), saveOptions);
Attached file is .msg file packed to zip due to upload restrictions.Test.zip (19.1 KB)