Copied Header/Footer not being displayed


I have two documents and im trying to copy the header/footer from one
doc to other doc. I use the code that I found in this forum and the
copying works but my problem is that when I open the new document
although the header/footer has been copied it doesnt get displayed
until I go Insert->Header from the menu and i wouldnt see the
FirstPageHeaderFooter unitl I check the “Different First Page” checkbox.

Is there any way make them display authomatically as currently the copied header/footer wouldnt get printed or exported to html.




Thanks for your request. I think you should also set DifferentFirstPageHeaderFooter and OddAndEvenPagesHeaderFooter. See the following code snippet:

sectA.PageSetup.DifferentFirstPageHeaderFooter = sectB.PageSetup.DifferentFirstPageHeaderFooter;
sectA.PageSetup.OddAndEvenPagesHeaderFooter = sectB.PageSetup.OddAndEvenPagesHeaderFooter;

Hope this helps.
Also, please provide me your code and sample documents.
Best regards.