You can automatically insert page numbers into a table of contents, that will update to reflect the latest page number in the PDF. Here’s how:
Note
Design options are currently somewhat limited for automatically-inserted page numbers in a table of contents, and for table of contents generally. We’re actively seeking feedback on what kinds of options you’d like to see, and how you’d like to work with them. Send us an email at support@hederis.com with any thoughts or feedback you might have.
First, the TOC must be set up in the Word file using hyperlinks, following the instruction in “Setup a Table of Contents Manually”.
In the Hederis app, open your table of contents in the Design preview, and click to select the text inside one of the TOC entries. You want to make sure that the “Inline link” element has been selected.
Scroll down to the Dynamic Content design options. Depending on whether you want the page number to appear before or after the TOC text, choose either the “Before Content” or “After Content” option.
If the “normal” checkbox is selected, uncheck it.
If you want any text or white space to precede the page number, type it first, surrounded by quotation marks, and then press Enter on your keyboard.
Type or paste the following text in the content box to insert the page number placeholder, and then press Enter on your keyboard: target-counter(attr(href url), page)
Tip
Usually you need to surround your text with quotation marks, but in this instance you need to leave out the quotation marks. This is a special instruction for the layout engine, rather than plain text, and leaving off the quotation marks helps convey that message.
Again, if you want any text or white space to follow the page number, type it, surrounded by quotation marks, and then press Enter on your keyboard.
Press “Reflow Pages” to preview the change. The page numbers will appear as “0” in the Design preview, and will be auto-filled with the correct page number when you build the PDF.
If you’re happy with the change, press Save Design.