Hi All,
We are using aspose.words dll for conversion of html to word. we have requirement to show different background image for First and following pages.
How to implement this with aspose.words ?
Do you have sample code for it?
In your case, we suggest you following solution.
- Please set the value of PageSetup.DifferentFirstPageHeaderFooter property as true for the first section of document.
- Move the cursor to the HeaderFirst of first section using DocumentBuilder.MoveToHeaderFooter method and insert the image.
- Move the cursor to the HeaderPrimary of first section using DocumentBuilder.MoveToHeaderFooter method and insert the image.
- Move the cursor to the start of document and insert section break (continuous).
- Save the document.
We suggest you please read the following article.
Using DocumentBuilder to Modify a Document Easily
Use DocumentBuilder to Insert Document Elements
A post was split to a new topic: How to Insert different background images in the header of document