Hi George,
Try the following macro:
Code:
Sub Demo()
Application.ScreenUpdating = False
With ActiveDocument.Range
.InsertBefore vbCr
.AutoFormat
With .Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = "^13[!^13\-]{1,}"
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindStop
.Format = False
.MatchWildcards = True
.Execute
End With
Do While .Find.Found
With .Duplicate
.Start = .Start + 1
.Font.Bold = True
End With
.Collapse wdCollapseEnd
.Find.Execute
Loop
End With
ActiveDocument.Paragraphs.First.Range.Delete
Application.ScreenUpdating = True
End Sub
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Last edited by macropod; 08-08-2012 at 04:48 PM.
Reason: Code fix
|