The text is getting cut off when converting an email (.msg) to pdf.
The text is in tables in the email body.
Using Outlook to save the .msg file as either .htm or .mht saves the file and displays it correctly.
Our code uses the AutoFitToWindow for the tables.
foreach (Table table in doc.GetChildNodes(NodeType.Table, true))
{
table.AutoFit(AutoFitBehavior.AutoFitToWindow);
}
Original msg and pdf rendition included: __rendertests.zip (139.4 KB)
Aspose.PDF version 20.5
Aspose.Email version 20.4
Aspose.Words version 20.5
I suggest you to please first try using latest Aspose.Email, Aspose.PDF and Aspose.Words version on your end. Then please try to save the MSG and MHTM file and see if the rendering has been done right in MHTML by comparing it with MSG file. If there is no issue between MSG file and MHTML file then it is issue on Aspose.Words or Aspose.PDF end where you are further processing the MHTML to PDF. However, if there is issue observed in MHTML then its an issue related to Aspose.Email. Therefore, I suggest you to please perform the recommended test on your end and share feedback. Please also provide the working sample example that is reproducing the issue on your end.
@davno fter working with sample project, I have found that till MHTML, the output is generated fine. The problem occurs when it is exported to PDF. I am moving this thread to concerned forum where our team will assist you further in this regard.
Please note that Aspose.Words mimics the behavior of MS Word. If you convert your MHT to PDF using MS Word, the output will not be correct. However, we have logged this issue as WORDSNET-21440 in our issue tracking system. You will be notified via this forum thread once this issue is resolved. We apologize for your inconvenience.
@tahir.manzoor
I tested saving the .mht as a .pdf in both Word 2013 and Word 365 (desktop) and while the text wrapping is not exactly the same as the .mht file, the text does wrap and all text is visible. The .pdf generated through your dll cuts off the text. This is not the same behavior as Word.
Thanks for sharing the detail. We have logged this detail in our issue tracking system. We will inform you via this forum thread once there is an update available on it.
Unfortunately, there is no further update available on this issue at the moment. We will be sure to inform you via this forum thread once there is an update available on it.