Microsoft KB Archive/72763

{|
 * width="100%"|

How to Create Multiple Tables of Contents

 * }

Q72763

-

The information in this article applies to:


 * Microsoft Word for Windows, versions 2.0, 2.0a, 2.0a-CD, 2.0b, 2.0c

-

SUMMARY
This article describes how to create separate tables of contents for lists of figures, tables, photos, and so forth.

NOTE: While the following information can be used in Word 6.x for Windows (all platforms) and Word 7.0 for Windows 95, the user interface for building multiple tables of contents has been substantially changed. The interface in these newer products is greatly simplified and does not require the direct manipulation of field codes that is required in Word version 2.x. For more information on creating separate tables of contents in these versions, look in Help under Tables.

Each TOC field after the first one must be entered by using the Field command on the Insert menu or by pressing CTRL+F9. In Word versions 1.x and 2.x, you cannot create two tables of contents in the same document with the Insert Table Of Contents command, even if you give different heading levels for the second one. When you choose Table Of Contents from the Insert menu to create a second table of contents, the following message will appear:

Do you want to replace the existing table of contents?

The message offers you three choices: OK, Cancel, and Help. If you choose not to replace the existing table of contents, the first table of contents will be left intact.

In Word 6.x (all platforms) and Word 7.0, you can add multiple table of contents through the Insert menu. Choosing to insert a table of contents will bring up the same message as prior versions of Word for Windows, but you now have the option to choose &quot;No&quot; and thus create an additional table of contents.

MORE INFORMATION
You can use heading paragraphs or TC fields to generate tables of lists using the TOC field.

Creating Tables of Lists Using Heading Paragraphs
To create multiple tables of lists using heading paragraphs, assign a different heading level to each list. For example, use heading 7 to format the titles of tables, heading 8 to format the titles of photos, heading 9 for figures, and so on. To create the tables of lists, create a separate TOC field for each heading level. For example:

  Table of Tables {TOC \o &quot;7-7&quot;}

Table of Photos {TOC \o &quot;8-8&quot;}

Table of Figures {TOC \o &quot;9-9&quot;}

In this example, the &quot;\o&quot; switch tells Word to create a table of contents using heading paragraphs. The numbers in the fields restrict the table of contents entries to paragraphs formatted with that number heading level.

Creating Tables of Lists Using TC Fields
To create multiple tables of lists using TC fields, a list identifier must be used in each of the TC fields. For example,

  {TC &quot;Table 1&quot; \f t} is an entry for a list of tables. &quot;Table 1&quot; is the text that will appear in the table of contents. The &quot;\f&quot; switch tells Word that the following letter identifies the list for this entry to be collected into. The list identifier can be any single letter.

To create a table of contents for the list of tables, use the {TOC \f t} field. The &quot;\f&quot; switch in this field tells Word to compile the table of contents using TC fields. If no identifier is given, Word will compile all TC fields in the document.

When you use TC fields for the table of contents, you may also use the &quot;\l&quot; switch to designate a level for a given list. This switch is placed in the TC field. Each level is indented 0.5 inch from the previous level. For example, the field {&quot;TC Table 1&quot; \f t \l 3} will cause Word to indent this entry in the table of tables one inch from the left margin.

NOTE: There is a documentation error in on-line help for Word for Windows 2.0, 2.0a, 2.0a-CD, 2.0b, 2.0c, as well as in the printed fields documentation provided with the Word for Windows Macro Development Kit. In the help topic for the TOC field, the following example is given:

For example, if you want only heading 3 in your table, your code should be {toc \p 3-3}.

The field should read {toc \o 3-3}.