This sample shows how to add header and footer to PDF documents using Docotic.Pdf library.
You can use the PageLayout.Header and PageLayout.Footer methods to add common headers and footers to PDF pages. Use the TextContainer.CurrentPageNumber method to add a page number to the current page.
The library also provides ways to add common headers and footers within page body:
- Use the LayoutContainer.Table method to add a table. Then, use the
Table.Header
andTable.Footer
methods. - Use the LayoutContainer.Column method to add a column. Then, use the
Column.Header
andColumn.Footer
methods.
This sample code uses free Docotic.Pdf.Layout add-on for Docotic.Pdf library.