How would any method know that your
2. Text
was to become
1.1 Text
and that
3. Text
was to become
2. Text
and so on?
Or, did you just give a bad example?
If your text is separated from the numbers by a tab stop and you
associated the numbering that you want to use with Heading styles
(See the following page of fellow MVP Shauna Kelly's website -
http://www.ShaunaKelly.com/word/numbering/OutlineNumbering.html
Running a macro containing the following code will convert the first
level of numbering to Heading 1 style
Dim drange As Range
Selection.HomeKey wdStory
Selection.Find.ClearFormatting
With Selection.Find
Do While .Execute(FindText:="[0-9]{1,}.^9", Forward:=True, _
MatchWildcards:=True, Wrap:=wdFindStop, MatchCase:=False) = True
Set drange = Selection.Range
drange.Text = ""
drange.End = drange.Paragraphs(1).Range.End
drange.Style = "Heading 1"
Loop
End With
For the second level, replace
"[0-9]{1,}.^9"
with
"[0-9]{1,}.[0-9]{1,}.^9"
and the Heading 1 with Heading 2
and for the third level you would use
"[0-9]{1,}.[0-9]{1,}.[0-9]{1,}.^9"
For an explanation of what is being looked for, see the following page of
fellow MVP Graham Mayor's website
http://www.gmayor.com/replace_using_wildcards.htm