Export (0) Print
Expand All

Indexes.Add Method

Returns a Index object that represents a new index added to a document.

Namespace:  Microsoft.Office.Interop.Word
Assembly:  Microsoft.Office.Interop.Word (in Microsoft.Office.Interop.Word.dll)

Index Add(
	Range Range,
	ref Object HeadingSeparator,
	ref Object RightAlignPageNumbers,
	ref Object Type,
	ref Object NumberOfColumns,
	ref Object AccentedLetters,
	ref Object SortBy,
	ref Object IndexLanguage
)

Parameters

Range
Type: Microsoft.Office.Interop.Word.Range
Required Range object. The range where you want the index to appear. The index replaces the range, if the range isn't collapsed.
HeadingSeparator
Type: System.Object%
Optional Object.The text between alphabetic groups (entries that start with the same letter) in the index. Can be one of the following WdHeadingSeparator constants: wdHeadingSeparatorBlankLine, wdHeadingSeparatorLetter, wdHeadingSeparatorLetterFull, wdHeadingSeparatorLetterLow, or wdHeadingSeparatorNone.
RightAlignPageNumbers
Type: System.Object%
Optional Object. True to align page numbers with the right margin.
Type
Type: System.Object%
Optional Object. Specifies whether subentries are on the same line (run-in) as the main entry or on a separate line (indented) from the main entry. Can be either of the following WdIndexType constants: wdIndexIndent or wdIndexRunin.
NumberOfColumns
Type: System.Object%
Optional Object. The number of columns for each page of the index. Specifying 0 (zero) sets the number of columns in the index to the same number as in the document.
AccentedLetters
Type: System.Object%
Optional Object. True to include separate headings for accented letters in the index (for example, words that begin with "À" and words that begin with "A" are listed under separate headings).
SortBy
Type: System.Object%
Optional Object. The sorting criteria to be used for the specified index. Can be either of the following WdIndexSortBy constants: wdIndexSortByStroke or wdIndexSortBySyllable.
IndexLanguage
Type: System.Object%
Optional Object. The sorting language to be used for the specified index. Can be any of the WdLanguageID constants.

An index is built from Index Entry (XE) fields in a document. Use the MarkEntry method to mark index entries to be included in an index.

Community Additions

ADD
Show:
© 2014 Microsoft