[Libreoffice] Copy Header/Footer from one Writer document to another

Grover Blue grover.blue at gmail.com
Thu Jun 30 14:20:23 PDT 2011

Does anyone have a Java example of copying header/footer contents between
documents?  I'm able to copy text, but the text format is not retained.
Additionally, images are copied, but not anchored to the page header I'm
insert them to.

Here is what I have:

fromXText = (XText) FileManager.getOOoUnoRuntimeQueryInterface(XText.class,

toXText = (XText) FileManager.getOOoUnoRuntimeQueryInterface(XText.class,

if (xViewCursor != null) {
    xViewCursor.gotoRange(toXText, false);

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20110630/83e2396b/attachment.html>

More information about the LibreOffice mailing list