Table of Contents

Introduction

The element <TOC> specifies the Table of Contents for the output document. The <TOC> element contains the following elements:

Setup Information for the <TOC>

The setup information specifies:

  • The PDF file AppendPDF Pro uses for the TOC.
  • Alternate bookmark text is used to identify the Table of Contents in the bookmark pane if other than “Table of Contents.”
  • A stamp file to stamp any optional text or images onto the TOC.

The table below describes the Elements for specifying setup information for <TOC>.

Contents of the <TOC> Element

Element Level Pro Required Content
<appendparam version=”1.0″> Top   Topmost element, contains entire parameter spec
     <toc> 2 Pro   Table of Contents information
            <file> 3 Pro Text: Name and path of TOC file
            <bookmarktext> 3 Pro   Text: Alternate bookmark text
            <stampfile> 3 Pro   Text: Name and path of stampfile to use

XML Code Sample

<appendparam version="1.0">
 <!-- . Indicates skipped sections -->
 <!-- . -->
 <!-- . -->
   <TOC>
      <file>
         /fullpath/TOC.pdf
      </file>
      <bookmarktext>
         Alternate bookmark text
      </bookmarktext>
      <stampfile>
         /fullpath/stamptoc.txt
      </stampfile>
 <!-- . -->
 <!-- . -->
 <!-- . -->
   </TOC>
 <!-- . -->
 <!-- . -->
 <!-- . -->
</appendparam>

Elements for setup information of <TOC>

file

Specifies the path and filename of a PDF file to be used for the Table of Contents. AppendPDF Pro will only use the first page of the Table of Contents file. It will add additional copies of the first page as needed.

The file used for the Table of Contents page should not contain any bookmarks. AppendPDF Pro adds its own bookmark.

bookmarktext

Specifies alternate text to appear in the bookmark pane identifying the Table of Contents. The default is “Table of Contents” but you can call it anything you want.

stampfile

Specifies the path and filename of a stamp file specifically for the Table of Contents. Can be used to stamp company information and page numbers, for example, onto Table of Contents pages. Refer to Stamp Files, for more information about stamp files.

Note: Table of Contents pages, Cover pages, and body pages each use an independent stamp file. A <stampfile> listed in the <TOC> section is applied only to the TOC pages and will not affect the cover or the body pages of the output PDF.

Usage notes for the Setup Information elements of <TOC>

All text entered onto the Table of Contents by AppendPDF Pro is linked to the respective pages in the new document.

Example

Specifying alternate bookmark text and a stampfile:

<TOC>
   <file>
      /fullpath/TOC.pdf
   </file>
   <stampfile>
      /fullpath/tocstamp.txt
   </stampfile>
   <bookmarktext>
      TOC Page
   </bookmarktext>
 <!-- . Indicates skipped sections -->
 <!-- . -->
 <!-- . -->
</TOC>