ListType Property

Microsoft Word Visual Basic

Show All

ListType Property

       

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

WdListType can be one of these WdListType constants.
wdListBullet
wdListListNumOnly
wdListMixedNumbering
wdListNoNumbering
wdListOutlineNumbering
wdListPictureBullet
wdListSimpleNumbering

expression.ListType

expression   Required. An expression that returns a ListFormat.

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