2019.2

Table Of Contents
What to use a Post Pagination Script for
After all Print sections have been paginated, Post Pagination Scripts may search through the
rendered document and collect information about elements (for instance, which page they
reside on) and sections (for instance, whether they are enabled). With this information, a Post
Pagination Script can do two things:
l
Modify the output. The script may modify the output of a section. It could, for example,
use information like page numbers to create a Table Of Contents (TOC), as explained in
the topic: "Creating a Table Of Contents" on the facing page. If needed, a Post Pagination
Script can re-paginate the section (see "paginate()" on page1404.
l
Add information to the Connect database. The script may add production information,
such as the page, size or position of elements after a merge, as custom properties to a
Print Content Item in the Connect database (see "contentitem" on page1386). Custom
properties can be utilized for further processing in a Workflow configuration with the
Retrieve Items task. The Retrieve Items task retrieves custom properties along with the
base record information (see Retrieve Items in Workflow's Online Help).
Adding a Post Pagination Script
To add a Post Pagination Script:
1.
On the Scripts pane at the bottom left, click the black triangle on the New button and click
Post Pagination Script. The new script appears in the Post Pagination folder.
2. Double-click the new script to open it. The script editor appears.
3. Change the name of the script so that it reflects what the script does.
Note
Scripts can only have the same name when they are not in the same folder.
4. Write the script. If you are not familiar with scripting, see "Writing your own scripts" on
page853.
Page 901