ConvertNumbersToText Method

Microsoft Word Visual Basic

expression.ConvertNumbersToText(NumberType)

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

NumberType    Optional Variant. The type of number to be converted. Can be any of the following WdNumberType constant.

WdNumberType can be one of these WdNumberType constants.
wdNumberParagraph
wdNumberListNum Default value for LISTNUM fields.
wdNumberAllNumbers Default value for all other cases.

Remarks

There are two types of numbers: preset numbers (wdNumberParagraph), which you can add to paragraphs by selecting a template in the Bullets and Numbering dialog box; and LISTNUM fields (wdNumberListNum), which allow you to add more than one number per paragraph.

The ConvertNumbersToText method is useful if you want to work with a document in another application and that application doesn't recognize list formatting or LISTNUM fields.

After you've converted list numbers to text, you can no longer manipulate them in a list.

Example

ShowAs it applies to the Document object.

This example converts the list numbers and LISTNUM fields in the active document to text.

ActiveDocument.ConvertNumbersToText
				

ShowAs it applies to the List object.

This example converts the numbers in the first list to text.

ActiveDocument.Lists(1).ConvertNumbersToText
				

ShowAs it applies to the ListFormat object.

This example converts the preset numbers in myRange to text without affecting any LISTNUM fields.

Set myDoc = ActiveDocument
Set myRange = _
    myDoc.Range(Start:=myDoc.Paragraphs(12).Range.Start, _
    End:=myDoc.Paragraphs(20).Range.End)
myRange.ListFormat.ConvertNumbersToText wdNumberParagraph