table on contents in word 2003

  • Thread starter Wendy Elizabeth
  • Start date
W

Wendy Elizabeth

I want to add sections to an existing Word 2003 document that contains a
table of contents. How do you make changes to the Word 2003 document so that
the table of contents is automatically updated?

Thanks!
 
S

Stefan Blom

TOCs don't update automatically. You can update them manually, by selecting
them and pressing F9. Alternatively, you can have them update prior to
printing, by choosing the option to update fields on print, in Tools |
Options, Print tab.

A different approach is to use the following macros in normal.dot or in an
add-in (which will update any tables of contents and tables of figures
present in the active document):

Sub FilePrintDefault()
Dim toc As TableOfContents
Dim tof As TableOfFigures
For Each toc In ActiveDocument.TablesOfContents
toc.Update

Next toc

For Each tof In ActiveDocument.TablesOfFigures
tof.Update
Next tof

ActiveDocument.PrintOut

End Sub

Sub FilePrint()
Dim toc As TableOfContents
Dim tof As TableOfFigures
For Each toc In ActiveDocument.TablesOfContents
toc.Update

Next toc

For Each tof In ActiveDocument.TablesOfFigures
tof.Update
Next tof

Dialogs(wdDialogFilePrint).Show

End Sub

If you need assistance, see http://www.gmayor.com/installing_macro.htm.

--
Stefan Blom
Microsoft Word MVP


in message
news:[email protected]...
 
Top