WD: How to Create a Table of Contents and Index with Field Codes

Last reviewed: February 3, 1998
Article ID: Q125937
The information in this article applies to:
  • Microsoft Word for Windows, versions 6.0, 6.0a, 6.0c
  • Microsoft Word for Windows 95, versions 7.0, 7.0a
  • Microsoft Word for the Macintosh, version 6.0, 6.0.1, 6.0.1a
  • Microsoft Word for Windows NT, version 6.0
  • Microsoft Word 97 for Windows

SUMMARY

This article describes how to accomplish the following:

  • How to create table-of-contents entry fields (TC fields) and index entry fields (XE fields)
  • How to build a table of contents from TC fields
  • How to build an index from XE fields

HOW TO CREATE A TABLE OF CONTENTS

Marking Table of Contents Entries

Method 1: a. Add the MarkTableofContentsEntry command to the Insert

             menu so that you can mark table of contents text using the
             menu:

             Word 97
             -------

             1) On the Tools menu, click Customize. The Customize
                dialog box displays.

             2) On the menu bar, click Insert. The Insert menu
                displays.

             3) In the Customize dialog box, click the Commands tab.

             4) In the Categories list, select All Commands.

             5) In the Commands list, select MarkTableOfContentsEntry
                and then click and drag the MarkTableOfContentsEntry
                command to the Insert menu. A horizontal bar displays
                showing you the position where the command will be
                placed on the menu. Release the mouse button when you
                locate the position you want.

             6) In the Customize dialog box, click the Close button.

             Word 6.x, 7.0
             -------------

             1) On the Tools menu, click Customize.

             2) Click the Menus tab.

             3) In the Categories list, select Insert.

             4) In the Commands list, select MarkTableOfContentsEntry.

             5) From the Change What Menu list, select Insert, and
                click the Add button.

             6) Click Close.

          b. Mark the text for inclusion in the table of contents:

             1) Select (highlight) the text you want to include.

             2) On the Insert menu, click Mark Table Of Contents Entry.

             3) Follow steps c through g of Method 2.

             4) Repeat steps 1 through 3 of this procedure for each
                table of contents entry in your document.

Method 2: Mark table of contents entries with the keyboard:

          a. Select the word(s) that you want to include as a
             table of contents entry.

          b. Press ALT+SHIFT+O (Word for Windows) or
             COMMAND+OPTION+SHIFT+O (Word for the Macintosh). The Mark
             Table of Contents Entry dialog box displays.

          c. In the Entry box, modify the text if you want it to be
             different than the selected text.

          d. From the Table Identifier list, select C for Table of
             Contents.

          e. In the Level list, select a level for the table of
             contents entry.

          f. Click the Mark button.

          g. Click the Close button.

          g. Repeat steps a through g for each table of contents entry
             in your document.

Building the Table of Contents

  1. Position the insertion point where you want your table of contents to appear.

  2. On the Insert menu, click Index And Tables.

  3. Click the Table Of Contents tab, and then click the Options button.

  4. Select the Table Entry Fields check box, and choose any styles you also want to include in the table of contents.

  5. Click OK.

  6. Click OK.

INDEXES

Marking Index Entries

Method 1: a. Add the MarkIndexEntry command to the Insert menu:

             Word 97
             -------

             1) On the Tools menu, click Customize. The Customize
                dialog box displays.

             2) On the menu bar, click Insert. The Insert menu
                displays.

             3) In the Customize dialog box, click the Commands tab.

             4) In the Categories list, select All Commands.

             5) In the Commands list, select MarkIndexEntry and then
                click and drag the MarkIndexEntry command to the Insert
                menu. A horizontal bar displays showing you the
                position where the command will be placed on the menu.
                Release the mouse button when you locate the position
                you want.

             6) In the Customize dialog box, click the Close button.

             Word 6.x, 7.0
             -------------

             1) On the Tools menu, click Customize.

             2) Select the Menu tab.

             3) In the Categories list, select Insert.

             4) In the Commands list, select MarkIndexEntry.

             5) In the Change What Menu list, select Insert, and then
                click the Add button.

             6) Click Close.

          b. Mark the text for inclusion in the index:

             1) Select (highlight) the text you want to include.

             2) On the Insert menu, click Mark Index Entry.

             3) Follow steps 3) through 6) of Method 2.

             4) Repeat steps 1 through 3 of this procedure for each
                index entry in your document.

Method 2: a. Use the standard menu commands to create your index
             entries:

             1) On the Insert menu, click Index And Tables.

             2) On the Index tab, click the Mark Entry button.

             3) Type in the Main Entry and Subentry text and choose the
                desired options and page number format.

             4) Click the Mark button.

             5) Repeat steps 3 and 4 of this procedure for each index
                entry field.

             6) Click the Close button.

          b. Mark the index entries with the keyboard.

             1) Select the word(s) that you want to include as a index
                entry.

             2) Press ALT+SHIFT+X (Word for Windows) or
                COMMAND+OPTION+SHIFT+X (Word for the Macintosh). The
                Mark Index Entry dialog box displays.

             3) In the Main Entry box, modify the text if you want it
                to be different than the selected text. Type in the
                Subentry text and choose the desired options and page
                number format.

             4) Click the Mark button to mark the selected text or
                click the Mark All button to mark all occurrences of
                the selected text.

             5) Click the Close button.

             6) Repeat steps 2 through 5 of this procedure for each
                index entry field.

Method 3: Use a concordance index. Do this when you know which words
          you want to index, and you want to index all those words in
          the document at once.

          a. In a new document, insert a two-column table.

          b. In the left column, type the words in your document that
             you want to mark for indexing. Note these entries are case
             sensitive.

          c. In the right column, type the corresponding text that you
             want to appear in the index.

          d. Save and close this document.

          e. On the Insert menu, click Index And Tables.

          f. Click the Index tab.

          g. Click the AutoMark button.

          h. Select the file you created in steps a through d and click
             OK.

Building the Index

  1. Position the insertion point where you want your index to appear.

  2. On the Insert menu, click Index And Tables.

  3. Click the Index tab and then click OK.


Additional query words: index entry
Keywords : kbfield macword ntword winword word8 word95 word97
Version : WINDOWS:6.0,6.0a,6.0c,7.0,7.0a,97; MACINTOSH:6.0,6.0.1,6.0.1a
Platform : MACINTOSH WINDOWS
Issue type : kbhowto


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: February 3, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.