Hi jbc,
how about this one?
Checks whether a paragraph starts with a field.
if so, checks whether that field is of type wdFieldSequence.
if so, gets the length of that field's result.
Checks whether the character after the first field,
is in a field also.
If so, checks whether that field is of type wdFieldSequence, too.
If so, inserts a tab after the first field in the paragraph.
Sub Makro1()
Dim rTmp As Range ' a temporary range
Dim lFld As Long ' length of a field result
Dim cChr(1 To 2) As Object
ActiveWindow.View.ShowFieldCodes = False
Set rTmp = Selection.Paragraphs(1).Range
Set cChr(1) = rTmp.Characters(1)
If cChr(1).Fields.Count = 1 Then
If cChr(1).Fields(1).Type = wdFieldSequence Then
lFld = Len(rTmp.Fields(1).Result)
End If
Set cChr(2) = rTmp.Characters(1 + lFld)
If cChr(2).Fields.Count = 1 Then
If cChr(2).Fields(1).Type = wdFieldSequence Then
rTmp.Characters(lFld).InsertAfter chr(9)
End If
End If
End If
End Sub
--
Greetings from Bavaria, Germany
Helmut Weber, MVP WordVBA
Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"