How to tell if a header is "first page only"

Is there a way to understand if a header is for all pages or “first page only”?

I have the following code:

for (Object cn : doc.getChildNodes(NodeType.HEADER_FOOTER, true))
{
    if (cn instanceof HeaderFooter) {
    HeaderFooter headerFooter = (HeaderFooter)cn;
    if (headerFooter.isHeader())
    {

    }
}

@kerner You can use HeaderFooter.HeaderFooterType property. See HeaderFooterType.HEADER_PRIMARY field.

1 Like