Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    May 2003
    Posts
    120
    Thanks
    0
    Thanked 0 Times in 0 Posts

    How to exclude a heading from the TOC (WordXP)

    I have some text with the Heading Level styles that I want excluded from the TOC. What is the best way to do this?

  2. #2
    Super Moderator
    Join Date
    Jan 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    3,852
    Thanks
    4
    Thanked 259 Times in 239 Posts

    Re: How to exclude a heading from the TOC (WordXP)

    TOCs can be built using bookmarked ranges so you could create a bookmark enclosing all the text that you want included in the TOC and then add that switch to the TOC field code.

    If the part you don't want included is in the middle then you have more of a problem. I would probably do this by creating new styles that look exactly the same as the heading styles and use these styles where you don't want the TOC to include.
    Andrew Lockton, Chrysalis Design, Melbourne Australia

  3. #3
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: How to exclude a heading from the TOC (WordXP)

    Hi Marie:

    You can create a TOC for e.g. of Heading 1 & Heading 3 by using:
    { toc t "Heading 1, Heading 3" }

    However, if you want Heading 3 to be at a different level than Heading 1, you must specify the level number.

    The syntax for custom TOC levels is:

    { TOC o "StartNumber-EndNumber" t "StyleName,level,NextStyleName,level" }

    where o "StartNumber-EndNumber" specifies the range of the standard heading style to be used; i.e. if NO special style or level is specified, it will create a TOC from whatever range is specified. Heading 1 can only be a level 1, Heading 2 at level 2, etc. e.g. "2-3" will create a TOC from Headings 2 & 3 only, at their respective levels.

    t This switch allows you to specify which styles you wish to use in the TOC. It allows you to select nonstandard styles AND allows you to select standard styles (Heading 1 thru 9), but specify a custom TOC level (indentation).

    For example, {TOC o "3-3"} will create a TOC of Heading 3 style only, & indent it in the TOC to level 3. However, if you wanted Heading 3 to be at level one, the syntax is: {TOC o "3-3" t "Heading 3,1"}

    If you place "StyleNames,Number, after the t switch, it will use those styles & will place them at the level specified. The t switch overrides the range listed after the o switch.
    Hope this helps,

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •