Add a table of contents to the publication
You can optionally insert a table of contents in the document by defining the hierarchy of heading levels that are to be included. You can add a table of contents to your template via two methods:
- Use the Microsoft Word mechanisms to add a table of contents anywhere in the Word template. The publication will have a table of contents at the specified position that reflects the current content. This mechanism can only be used if the formatting of the headings is based on styles with a heading level.
- If you create the Word template without a table of contents, you can configure the publication definition in Alfabet Expand to add a table of contents to the document during publication. The table of contents will be inserted before the Word template. This method is not recommended for templates containing a title page because the table of contents will be located before the title page. this method is described in this section.
For either method, the table of contents will not be automatically filled during document creation. When a user opens a publication, he/she will see the text 'TOC' where the table of contents has been added. The user must update the table of contents manually to view the contents. To do so, the user must click the word 'TOC' and press F9 on his/her keyboard.
- click the publication node in the explorer.
- In the attribute window, set the Insert Table of Contents to True.
- Expand the attribute section and set the attributes:
- Start Level: Define the first heading level that shall be included in the table of contents.
- End Level: Define the last heading level that shall be included in the table of contents.
- Heading: Enter the text that shall be displayed as heading text above the table of contents.
- Heading Style Name: Enter the style name that shall be used to format the heading of the table of contents. The style must exist in the style configuration of your Word template.
- Separate Page: Select True if a page break shall be inserted after the table of contents.
- In the toolbar of Alfabet Expand, click the Save
button.