Menu

Need training at your office? Request a quote for custom training.

Home / Adobe FrameMaker / Adobe FrameMaker: Including chapter numbers in a table of contents

Adobe FrameMaker: Including chapter numbers in a table of contents

by Barb Binder, Adobe Certified Instructor on FrameMaker
Updated: May 23, 2020

From a recent Rocky Mountain Training FrameMaker student:

Hope you and your classes are going well. I have a quick question that I was hoping you could help me with:  I am making a table of contents (TOC) for my book, but when I create the TOC, everything looks fine, except I lose the Chapter #’s.  For example, it will just have the chapter title like “How to cook an egg” vs. what I’m looking for: “Chapter 1 How to cook an egg.”  This is only in the TOC, the chapter titles are just fine in the individual files. Any help would be appreciated 🙂

This is an easy one to remedy. Remember that the generated files (i.e., TOC or index) store their structure information on the reference pages. One quick addition to the TOC reference page and you will be good to go. Here are the steps:

  1. Open the table of contents file. In this example, the three chapter titles are missing their chapter numbers.
    ss_002
  2. View > Reference pages.
  3. Navigate to the TOC reference page.
  4. Locate the paragraph that controls the chapter titles. In this example, I called my titles ChapterTitle in the source documents, so the tag I’m looking for is ChapterTitleTOC. 
    TIP Click each building block until you find the one tagged TitleTOC or ChapterTitleTOC, which represents the chapter titles from the source documents. The tag name will appear in the lower left corner of the status bar.
    ss_005
  5. Add the words Chapter <$Chapnum>: and a space in front of the appropriate <$paratext> building block
    ss_004
  6. View > Body pages.
  7. File > Save.
  8. Update your book.
    When you update your book, FrameMaker reads the new instructions on the reference page, and adds the word Chapter, the chapter number and the punctuation/spacing in front of the original chapter titles.
    ss_003

More posts on using generated files in FrameMaker

Adobe FrameMaker: What to know about working with generated files

Adobe FrameMaker: Adding tabs to a table of contents

Adobe FrameMaker: Removing bold from page numbers in a table of contents

Adobe FrameMaker: More on customizing a table of contents

Adobe FrameMaker: Reusing a TOC or Index

Adobe FrameMaker: List of markers

Adobe FrameMaker: How to create a list of effective pages

Adobe FrameMaker: Creating a simple glossary for a book

Leave a Comment

Your email address will not be published. Required fields are marked *

9 thoughts on “Adobe FrameMaker: Including chapter numbers in a table of contents

  1. Hi Barb,
    the PDF generated with Framemaker 2019 does not show the cover page any more. I had to change the settings for the numbering in the TOC file, because the chapter numbers in the bookmarks were different from those in the TOC. The TOC comes out correctly now but the cover is missing. Any suggestions which settings I need to configure?
    Thanks in advance.

    Best regards,
    Andrea

  2. Hi Andrea:

    How was the cover page added? As a .fm file listed individually in the book window, or as the first page of an .fm file? If the former, right-click it in the book window to make sure it isn’t set to “exclude”. If the latter, check to make sure the exported page range included the first page.

    ~Barb

      1. Hi Barb,
        the TOC shows the correct numbers now.
        The bookmarks, however, don’t count correctly.
        In Format / Document / PDF settings I have the first three headings on the left selected.
        Any suggestions? Help would be very much appreciated.
        Thanks in advance.

        Regards,
        Andrea

  3. Barb, I understand the process on how to show the Chapter titles in front of the headings but I’m trying to get the chapter number in the front of the page number, like 1-1, 1-2, or 2-1, 2-2 etc. in the TOC like they are already in the book. Any help would be appreciated. Thank you.

    1. Hi Ron:

      Instead of starting the line with <$chapnum> as per the blog post, add <$chapnum>– in front of <$pagenum> on the TOC reference page.

      <$paratext>\t<$chapnum>–<$pagenum>

      ~Barb

        1. Barb, I was able to get the 1-1, 1-2 and so on to work, but now I’m having trouble with the Chapter numbers not changing incrementally in front of the page numbers like, 1-1, 2-1, 3-1 under their specified chapters. Any help would be appreciated! Thank you!