Template: Header, footer and body area

Template: Header, footer and body area

If you want to create a normal business document, then you probably want to define a header, footer and body area in your template.

 

When you first create a new template, then you only have one container in the page element. All of the design elements inside the page element are all only executed once, but if you want to define a header and/or a footer, that is to be included on all output pages, then you need to add a header and a footer section to the page.

 

You can do that by right clicking on the page element and then select header and/or footer like below:

 

NG2HeaderFooter0001

 

Inside the header and the footer you can insert the contents, that should be repeated for all the output pages. The header and footer does however not need to be fixed. You can e.g. use conditions via either the if element or the select element to define one header/footer for the first page of a document and another header/footer for the rest of the document.

 

You can also consider to use components to reuse the header and/or footer for multiple document types (invoices, credit notes, order confirmations etc.).

 

In the body area you can insert a repeat element to iterate across all the detail lines of the input file and generate a page overflow, when there is not enough room for more detail lines on the current page.

 

Here is a video that introduce the use of a header and footer:



 

 



    • Related Articles

    • Template examples

      This section includes some template examples: 1.The options for handling detail lines. 2.Set a header, footer and body area for a normal business document. 3.Large header on page 1 only. 4.Make room for total on last page. 5.Labels filled out from ...
    • Page body

      The body section of a page If you have inserted either a header or a footer element to a page element, then a body element is also added: The body elements contains the elements, that should only be executed/inserted once. This section normally ...
    • Template: Large header on page 1 only

      When you design a business document e.g. an invoice, then you might want a large header on page 1 and a much smaller header on the subsequent pages of your document. In the section below you can see, how you can create such a flexible header. First ...
    • Page footer

      Page footer If you want to keep the same footer for all pages of a merge, then you should normally insert them in a footer element of the page element. To create a page footer element you need to right-click on the page element in the element tree ...
    • Template: Make room for total on last page

      If you have a normal business document, then you are probably using the header and footer option for the template. A simple example is covered in the section, Template: Header, footer and body area. You might however have a special requirement for ...