Convert Word DOCX to PDF using C# .NET & Wrap Text around Floating Table Objects in Header

Hello experts,

I am converting a word document(docx) to PDF with Aspose.Words.dll.The word document has a header on its each page. There are some tables in the word documents. But after converting I found some headers were covered by the table.

The version of Aspose.Words.dll is “19.12.0.0”. The code I used is here:

using (var wstm = File.OpenRead(wordPath))
{
using (var pstm = new FileStream(pdfPath, FileMode.CreateNew))
{
Aspose.Words.Document doc = new Aspose.Words.Document(wstm);
doc.Save(pstm, Aspose.Words.SaveFormat.Pdf);
pstm.Flush();
}
}

I have attached the original word document(Operation.docx),the pdf document(testPdf.pdf) and a screenshot(pdfissue.png). You can see the issue on page 30 of pdf document too. Please notice that I can’t use the Aspose.Words.dll whose version is later than 20.0.0.0 because my project is based on .Net Framework 3.5
pdf.zip (909.4 KB)
Please advise.

@TommyZhou,

We tested the scenario and have managed to reproduce the same problem on our end. For the sake of corrections, we have logged the following issues in our issue tracking system.

WORDSNET-20304: Content pushed upwards in all pages of PDF
WORDSNET-20305: Content overlaps or hides header’s content in PDF (pdfissue.png)

We will further look into the details of these issues and will keep you updated on the status. We apologize for your inconvenience.

1 Like

Hi @awais.hafeez,

Is there any update about this?

Thanks,

@TommyZhou,

I am afraid, both issues (WORDSNET-20304 & WORDSNET-20305) are related and because of complexity the implementations of these issues have been postponed till a later date. There are no estimates available at the moment. Rest assured, we will inform you via this thread as soon as these issues will get resolved in future. We apologize for your inconvenience.

The issues you have found earlier (filed as WORDSNET-20305) have been fixed in this Aspose.Words for .NET 20.11 update and this Aspose.Words for Java 20.11 update.

The issues you have found earlier (filed as WORDSNET-20304) have been fixed in this Aspose.Words for .NET 23.5 update also available on NuGet.