Combining of documents causes text to slide onto new/extra page

Hi,
I am using Aspose.Words v. 9.1.0.0
I have two documents that I need to merge into a single document for users. The documents have different page margins. Document “A” has default/normal margins. Document “B” has very small top and bottom page margins for the first page due to requirements. I run into the following scenarios:

  1. If I generate the documents separately, they come out fine. No problems.
  2. If I generate the documents separately and then merge them in the order B then A, no problem.
  3. If I generate the documents separately and then merge them in the order A then B, then B gets page 1 broken onto 2 pages. Not good!!! :wink:

I need document B generated/merged last in the merged/resulting document.
I have tried mergeing the docs two ways 1) the “old” method of looping through the sections and doing an ImportNode call and 2) with the new AppendDocument method. Both give the same results noted above.
Any suggestions?

Hi

Thanks for your request. I cannot reproduce the problem on my side using the latest version of Aspose.Words (9.3.0). I use the following code for testing:

// Open Document Document docA = new Document(@"Test\A.doc");
Document docB = new Document(@"Test\b.doc");
docB.AppendDocument(docA, ImportFormatMode.KeepSourceFormatting);
// Save output document
docB.Save(@"Test\out.doc");

Please see the attached documents.
Could you please attach your documents here for testing? I will investigate the issue and provide you more information.
Best regards,