Including Page Autonumbers in Print Indexes

There are two basic methods for adding page autonumbers (i.e., page numbers that also include the chapter or volume autonumber) to print-based output—(1) by inserting variables into page layout frames or (2) by setting the autonumbers on the outline TOC entries where new "chapters" start. With the first method, the autonumbers are shown on your main content pages, but they are not included in a generated print index. With the second method, the autonumbers are shown both on your main content pages and in a generated index. You would use the first method if you want a quicker process and are not including a print index, but you would use the second method if you need the autonumbers to show up in an index.

Methods

  • Insert Variables into Page Layout Frames (Not Supported in Print Index) With this method, you can insert the appropriate autonumber variables in your page layouts. This is the fastest and easiest solution if you are not also creating a print index. See Inserting Chapter, Section, and Volume Number Variables Into Frames and Inserting Page Numbers into Frames.

    Example You have a project with chapter autonumbers in topics that you have designed to be the start of new chapters in your output. In order to include those same chapter numbers in the page numbering, you opened your page layout, selected the footer frame, and pressed F2 to edit it.

    Inside that footer frame, you inserted a chapter number variable, typed a period, and then inserted a page number placeholder. Like this:

    Example of an autonumber variable in a page layout.

    When you view the generated output, you see the page numbers displayed correctly as 1.1, 1.2, 1.3, 2.1, 2.2, and so on. Unfortunately, if you also include a print index in the output, the page numbers are displayed as 1, 2, 3, 4, etc. In other words, the page numbers are shown in the index, but the chapter autonumbers are not.

  • Set Autonumbers on Outline TOC Entries (Supported in Print Index) If you intend to include a print index in the output, you should not insert the autonumber variable in the page layout. Instead, you should set the chapter or volume autonumbers in the TOC Editor, at the same locations where you create chapter breaks for the output. The following steps show you how to do this.

How to Set Autonumbers on Outline TOC Entries and Include in an Index

  1. Set up your topics to use chapter or volume autonumbers where appropriate (e.g., on the heading for a topic that will come first in a new chapter). See Autonumbers, Creating Autonumbers for Styles, and Creating Autonumber Formats for Paragraphs.
  2. Create your page layout(s). In the appropriate header or footer frames, insert a page number placeholder. Do not insert a chapter or volume number variable. See Page Layouts and Inserting Page Numbers into Frames.

    Example You have a project with chapter autonumbers in topics that you have designed to be the start of new chapters in your output. You want to include those same chapter numbers in the page numbering at the bottom of pages, and you also want them to display in a print index that you are creating.

    First, open your page layout, select the footer frame, and press F2 to edit it. Inside that footer frame, you insert a page number placeholder. When finished, it should look something like this:

    A page number placeholder in the page layout.

  3. Open your outline TOC and double-click an entry where you want to start a new chapter or volume. The Properties dialog opens.
  4. Select the Printed Output tab.
  5. In the Break Type field select Chapter Break and complete the other fields in that area as necessary. See Specifying Chapter and Page Layout Breaks.
  6. In the Page Number area, click in the Format field and select text.
  7. In the Reset to field, enter the appropriate commands. For a chapter autonumber, you can use {chapnum}. For a volume autonumber, you can use {volnum}. You can also insert any text, such as a period or dash, as well as a counter command, such as {n}.

    Example You want to display the chapter autonumber, followed by a period and then the page number. In that case, you would type the following:

    {chapnum}.{n}

    TOC properties showing autonumber commands defined for pages in printed output.

    The {chapnum} command indicates a chapter autonumber. If you had wanted to show the volume autonumber instead, you would have used the {volnum} command.

    Because you want a period to separate the chapter autonumber and the incremented page number, you simply type it. Then you add the page number command, which is {n}.

  8. Select the Autonumbers tab.
  9. For the first chapter or volume in your output, you will most likely want to select the appropriate Reset to option and enter 1. For subsequent chapters or volumes, you will probably want to select Increment number. See Specifying Autonumbering Flow for Output.
  10. Click OK.
  11. Repeat steps 3-10 for each TOC entry that is designed to start a new chapter or volume. By holding down the CTRL or SHIFT key, you can select multiple entries in the outline TOC and provide the settings for all of them at one time.
  12. Click Save the active file. to save your work.
  13. Create a topic to hold your print index and add it to your outline TOC . See Creating an Index Manually for Print.
  14. Build and view the output. See Step 5: Building and Publishing Output and Viewing Output.

    When you view the generated output, you will see the page numbers displayed correctly (e.g., 1.1, 1.2, 1.3, 2.1, 2.2, and so on). In the generated print index, you will see the same autonumber/page number combination—as long as your topics include index keywords (see Inserting Index Keywords).

What’s Noteworthy?

Note Only chapter and volume autonumbers are supported. Section autonumbers are not supported in this feature.