Need a solution such that the contents of very first page of a word document don't move to next page after mail merge

Dear Aspose Team,
We need to take care of a particular scenario in which contents of very first page should not go to next page after mail merge. It should autofit/adjust into the first page itself.
We have a template where address fields are mail merged with text containing multiple new lines and this is pushing contents from first page to next page and we want to stop this from happening.
The very first page in our word template looks like as follows:
Can you please let us know how to solve this issue?
Many thanks,
Chandra

Hi Chandra,

Thanks for your inquiry.

As you may know Microsoft Word document is a flow document and Microsoft Word layouts content of a document into lines and pages on the fly, therefore, if during mail merge the content goes vertically beyond the bounds of Page, it moves it to the next page. There are a few ways you can try to keep the content within a page.

Reduce the text Font size
Increase the Page’s height
Use of ParagraphFormat.SpaceAfter and ParagraphFormat.SpaceBefore properties could also be helpful.

Please let me know if I can be of any further assistance.

Best regards,

Thanks for this information.
Since first two options are not possible, I’ll try this -
Use of ParagraphFormat.SpaceAfter and ParagraphFormat.SpaceBefore properties could also be helpful.

Regards,
Chandra

Hi Chandra,

Sure, please let us know any time you have any further queries.

Best regards,