ShowHeadingNumber

Syntax

ShowHeadingNumber

Remarks

In outline view, shows all headings up to the specified heading level and hides subordinate headings and body text. Number is an integer from 1 to 9; you cannot use a variable in place of Number.

ShowHeadingNumber is available only in outline view and master document view; an error occurs if the statement is run in another view.

Example

This example takes advantage of outline view to easily reorder sections of the document. Consider an alphabetic reference whose headings, formatted as Heading 1 paragraphs, have gotten out of order; this macro can quickly alphabetize the sections. Collapsed headings and body text move with the Heading 1 paragraphs.


ViewOutline
ShowHeading1
EditSelectAll
TableSort .Order = 0

See Also

OutlineCollapse, OutlineExpand, OutlineShowFirstLine, ShowAllHeadings