MS Word

Remove Typed Numbering from Lists and Headings

The Problem:

My boss emails me numbered lists of tasks for everyone in the office. When I put them into our Assignment template, I need to delete all the numbers he's typed in, because the lists get automatic numbering from the styles. I know I can go through selecting each list and then clicking the Numbering button on the Formatting toolbar twice, once to remove the numbers and once to reapply them, but that messes up the list templates.

The Solution:

Create the short macro shown in Example 8-7 to remove the manually applied numbers from a selected list.

WordBasic Object

WordBasic was the programming language used in early versions of Word, before Microsoft applied VBA to Word. VBA includes a WordBasic object that enables you to use WordBasic commands, such as this one, via VBA.

Macro to remove manual numbering from a list

Example 8-7
Sub Remove_Manual_List_Numbering()
    WordBasic.ToolsBulletsNumbers Replace:=0,
                                     Type:=1,
                                    Remove:=1
End Sub


by BrainBellupdated
Advertisement: