InputTest.pdf (448.4 KB)
OutputTest.pdf (143.6 KB)
Hi,
We are loading the InputTest PDF using the Aspose.Word and Aspose.Words.Pdf2Word
using the below code, but the PDF loaded is completely misformated. PFA the Output test.
We want to load the PDF, move to a book mark, add a date time stamp there and then save the output in pdf. Is that possible using Aspose Words?
var doc = new Document("InputTest.pdf");
var builder = new DocumentBuilder(doc); // Insert text at the beginning of the document. builder.MoveToDocumentStart();
builder.Write("Test");
doc.UpdatePageLayout();
doc.Save("OutputTest.pdf");
thank you for your help and support.
@HealthcareInteractive Generally it is possible. However, you should note that Aspose.Words is designed to work with MS Word documents. MS Word documents are flow documents and they have structure very similar to Aspose.Words Document Object Model. But on the other hand PDF documents are fixed page format documents. While loading PDF document, Aspose.Words converts Fixed Page Document structure into the Flow Document Object Model. Unfortunately, such conversion does not guaranty 100% fidelity. I am afraid there is no way to 100% preserve PDF document Layout after PDF->Aspose.Words DOM->PDF roundtrip.
If you need to edit PDF documents and the target format is also PDF, Aspose.PDF would be the right product for this task.
https://docs.aspose.com/pdf/net/get-update-and-expand-bookmark/
We have managed to reproduce the problem and opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): WORDSNET-24920
You can obtain Paid Support services if you need support on a priority basis, along with the direct access to our Paid Support management team.
Thanks Alexey. Appreciate your quick response.
1 Like