we encounter some issues concerning page breaks at unwanted positions when saving a document to a pdf file. While Microsoft Word keeps the page breaks in the pdf file at the same positions as in the original document file, Spire.Doc for Java doesn't keep the page breaks when the document file is saved to pdf using the following code:
- Code: Select all
Document document = new Document("Test.docx");
document.saveToFile("Test_with_SpireDoc.pdf", FileFormat.PDF);
Please find attached the following files:
- Test.docx - the original document file
- Test_with_Word.pdf - the pdf file that was created when saving the original document file to pdf using Microsoft Word
- Test_with_SpireDoc.pdf - the pdf file that was created when saving the original document file to pdf using Spire.Doc for Java 11.7.0
Am I missing some important settings to keep the page breaks on their original positions?
Kind regards,
Marcus