Saving table of contents options for a template

J

johannblake

I have a template that contains no text. I use it strictly for setting
styles and the content that goes into headers and footers. What I want
to accomplish is to setup the formatting of the table of contents (TOC)
so that when a document is created from this template and a TOC is
inserted into the document, the TOC is formatted the way I set it up in
the template.

I have generally two problems. The first problem is that when I click
on the options button in the Table of Contents dialog, I remove the
styles Title and some others that I don"t want. Now I don't have any
text in my document that a TOC can be created from, so an error message
appears when Word attempts to insert the TOC. That should not be a
problem since I don't want any text. But when I go back and view the
options again, those styles I removed are still selected. How is this?
I don't want a title in my TOC but one ends up getting put in the TOC
in a document created from this template.

The other thing I don't understand is why some styles even appear in
the list of styles in the options dialog. I created a style called
Title1. Why does it even appear in this list? Does Word simply list all
the styles in my document in this list?

Thanks for your help
Johann Blake
 
G

Guest

Hi Johann,

To be certain that your TOC is only built from the styles you want, right
click the TOC and choose Toggle field codes to display the field codes. Now
delete any \x switch plus possible arguments that you see, and include only
the \t switch followed by the styles you want to use and the level they
represent, like for example

{ TOC \t "Heading 1;1;Heading 2;2;Heading 3;3" }

Do not use the Insert | Reference > Index and Tables... | tab Table of
Contents | Options... dialog again to avoid that styles you do not want sneak
their way in again. I have experienced the same behavior that you encounter
and I've had to rebuild my TOC's several times until I decided to leave the
dialog alone.

In answer to your second question: every new style that you create is
included. Word cannot know whether or not you want to use this style for your
TOC and if so, you would have a problem if it wasn't listed.

Good luck,
Cooz
 
S

Stefan Blom

The TOC is a field with instructions (so-called field switches) that
determine what should content should be referenced. This field is
created by Word as you insert the TOC via the Index and Tables dialog
box.

But, as you've seen, after you've created the TOC, there is no longer
a link between the dialog box and the field; instead, the dialog box
reflects the default settings for TOC creation in Word. For example,
you'll find that Heading 1-3 are selected, as well as any style with
an outline level defined (on the Indents and Spacing tab of the
Paragraph dialog box).

In other words, if you want to re-use a TOC format, you can copy an
existing TOC into a template, or insert one (with the desired styles
selected) directly in the template.

Note that a TOC field in an empty document will display an error
message (unless it has been copied from an existing document and not
yet been updated). If you don't like this fact, you can create an
AutoText entry from an existing TOC and insert that as needed.
 
S

Stefan Blom

in message
Hi Johann,

To be certain that your TOC is only built from the styles you want, right
click the TOC and choose Toggle field codes to display the field codes. Now
delete any \x switch plus possible arguments that you see, and include only
the \t switch followed by the styles you want to use and the level they
represent, like for example

{ TOC \t "Heading 1;1;Heading 2;2;Heading 3;3" }

Do not use the Insert | Reference > Index and Tables... | tab Table of
Contents | Options... dialog again to avoid that styles you do not want sneak
their way in again. I have experienced the same behavior that you encounter
and I've had to rebuild my TOC's several times until I decided to leave the
dialog alone.

In answer to your second question: every new style that you create is
included. Word cannot know whether or not you want to use this style for your
TOC and if so, you would have a problem if it wasn't listed.

But note that while each style is *listed* in the Options dialog box,
it isn't *selected* for inclusion in the TOC, unless it has an outline
level other than "Body text" (as seen on the Indents and Spacing tab
of the Paragraph dialog box).
 

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