Merging documents

Home Forums Open-Xml-PowerTools Merging documents

This topic contains 1 reply, has 2 voices, and was last updated by  Eric White 7 years, 8 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #3727

    gamartin
    Participant

    I am converting HTML content into WML and then merging that document with a template that has sections, a TOC, headers/footers etc. I need the content of the converted HTML to be in the last section of the template document, but the merge puts it in a new section, leaving the next to last section as an empty page.

    Is there any way to either force the merged content into the last section of the template, or to remove the “empty” section after the merge? I have tried the suggestions here to remove blank pages, but I imagine because of the header/footers on my page that it is not considered blank.

    Any thoughts?

    Garth

    #3769

    Eric White
    Keymaster

    Hi Garth,

    Have you reviewed all of the screen-casts on DocumentBuilder?

    http://www.ericwhite.com/blog/blog/documentbuilder-developer-center/

    Specifically, the last screen-cast shows how to deterministically work with headers/footers.

    One thing that you could do is to remove the sections from the document that you get after converting the Html to WordprocessingML. Just remove the w:sectPr elements from the body of the document.

    You can then control headers/footers using DocumentBuilder. In general, I believe that it is possible to do what you want to do. I am not fully sure of exactly where the error is occurring in your process, though.

    Cheers, Eric

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.