ListFormat.ListType Property (Word)

Returns the type of lists that are contained in the range for the specified ListFormat object. Read-only WdListType.

Syntax

expression .ListType

expression Required. A variable that represents a ListFormat object.

Remarks

The constant wdListListNumOnly refers to LISTNUM fields, which are fields that can be added within the text of a paragraph.

Example

This example checks to see if the first list in the active document is a simple numbered list. If it is, the fourth list template on the Numbered tab of the Bullets and Numbering dialog box (Format menu) is applied.

Set myList = ActiveDocument.Lists(1) 
If myList.Range.ListFormat.ListType = wdListSimpleNumbering Then 
 myList.ApplyListTemplate _ 
 ListTemplate:=ListGalleries(wdNumberGallery) _ 
 .ListTemplates(4) 
End If

See Also

Concepts

ListFormat Object

ListFormat Object Members