We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Linking the all headers in the document


I’m creating a document by filling the 6 different templates and appending them one after other.
The problem is every page its own header which makes the document size quite big(document had over 300 pages) and also having issues while printing the document. Is there way I can make document use link the headers

I tried using the following after appending all the templates to document but didn’t work

private void LinkHeaders(Document aobjDoc)

DocumentBuilder builder = new DocumentBuilder(aobjDoc);

foreach (Section section in aobjDoc.Sections)
if (section == aobjDoc.FirstSection) continue;

PageSetup pageSetup = section.PageSetup;
pageSetup.DifferentFirstPageHeaderFooter = false;



Hi Guri,

Thanks for your inquiry. Please check following documentation link to link Header and Footers from previous section. Hopefully it will help you to accomplish the task.

However, if there is any difference in your requirement and our understanding then please share your sample input and expected documents here. It will help us to understand your requirement and address it accordingly.

Best Regards,