ListTemplate Property

Microsoft Word Visual Basic

ListTemplate Property

       

Returns a ListTemplate object that represents the list formatting for the specified Style or ListFormat object.

expression.ListTemplate

expression   Required. An expression that returns one of the objects in the Applies To list.

Remarks

A list template includes all the formatting that defines a particular list. Each of the seven formats (excluding None) found on each of the tabs in the Bullets and Numbering dialog box (Format menu) corresponds to a list template. Documents and templates can also contain collections of list templates.

If the first paragraph in the range for the ListFormat object is not formatted as a list, the ListTemplate property returns Nothing.

Example

This example checks to see which list template is used for the second paragraph in the active document, and then it applies that list template to the selection.

Set myltemp = ActiveDocument.Paragraphs(2).Range. _
    ListFormat.ListTemplate
Selection.Range.ListFormat.ApplyListTemplate ListTemplate:=myltemp