Elements and headers/footers

  • Any hints on how to copy headers and footers from one element to another?

    An example might be when the user has created a document with data fields in element "@@FIRST@@" and I want the merged results in element "Merged". The doumentation shows how to merge the data fields....but to duplicate the user's original document, I also need to copy the headers/footers over...

    I am pretty sure this one is obvious and I have just missed it...

    • Offizieller Beitrag

    Hi,

    It is not possible to copy the data from one to another, but it is possible to save and load it.

    You need a variable:

    byte[] buffer;

    This saves the text

    buffer = wpdllInt1.GetBytes(1,false,"WPT")

    This loads the text

    wpdllInt1.SetBytes(1,buffer,"",false)

    To clear the body text (and keep header/footer) use this

    wpdllInt1.Memo.Clear(true,true)

    Kind Regards,

    Julian