Macro for Auto Table of Contents

E

EddieLampert

Any ideas on a macro that will automatically build a table of contents? I am
trying to avoid having to manually tag each page. Is there a way I can tag
the a certain part of each page, which will be updated when pages are added
to the document. Let me know if I'm not being clear. Any help is appreciated.
 
J

Jonathan West

EddieLampert said:
Any ideas on a macro that will automatically build a table of contents? I
am
trying to avoid having to manually tag each page. Is there a way I can tag
the a certain part of each page, which will be updated when pages are
added
to the document. Let me know if I'm not being clear. Any help is
appreciated.

You don't need a macro for this. You need a TOC field. You can specify what
paragraphs go into the Table of Contents by specifying the field switches.
 
E

EddieLampert

Thanks Jonathan. So if I specify with field switches, will I have to update
each time I add something that is to be included in the TOC? Can I set it to
the first line of the page (like a title) that is to be in the TOC, and not
include duplicates (if a "title" goes more than one page)? Thanks again.
 
J

Jean-Guy Marcil

EddieLampert said:
Thanks Jonathan. So if I specify with field switches, will I have to update
each time I add something that is to be included in the TOC? Can I set it to
the first line of the page (like a title) that is to be in the TOC, and not
include duplicates (if a "title" goes more than one page)? Thanks again.

I sense that you are not all that familiar with TOC in Word.
Basically, you can build a TOC based on paragraphs that are formatted with
certain styles, usually Heading 1 to Heading 9, but it can be any style. Or,
you can tag certain areas of the document with specialized fields and use
those fields to build the TOC. This is a bit more time consuming and advanced.
Also, you can link a TOC with certain part of a document using bookmarks,
thus generating more than one TOC per document.

For an overview see:
http://word.mvps.org/faqs/Formatting/TOCSwitches.htm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top