If the headings in your document have Styles applied to
them, choose Insert/Index and Tables (it's under
Reference in Word 2002), click the Table of Contents
tab. Then click Options, make sure Styles is ticked and
check in the list to make sure the Heading Styles you
want in your TOC have level numbers next to them. Put
your cursor where you want the TOC to appear, then click
OK twice and your TOC should appear. If it doesn't look
exactly the way you want it, you can modify the TOC
Styles.