One thing that you may be interested in is the situation whereby you need to
make numerous items BOLD. You have to reset things. Here's a sample code:
With .ActiveDocument.Content.Find
.ClearFormatting
.Text = "PAST MEDICAL HISTORY:"
.Forward = True
'.Replacement.Text = "PAST MEDICAL HISTORY:"
.Replacement.Font.Bold = True
.Execute Replace:=wdReplaceAll
End With
Call Resetsearch
With .ActiveDocument.Content.Find
.Text = "FAMILY HISTORY:"
.Forward = True
'.Replacement.Text = "FAMILY HISTORY:"
.Replacement.Font.Bold = True
.Execute Replace:=wdReplaceAll
End With
Call Resetsearch
With .ActiveDocument.Content.Find
.Text = "SOCIAL HISTORY:"
.Forward = True
'.Replacement.Text = "SOCIAL HISTORY:"
.Replacement.Font.Bold = True
.Execute Replace:=wdReplaceAll
End With
Call Resetsearch
etc etc
End Sub
Sub Resetsearch()
With Selection.Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = ""
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindContinue
.Format = False
.MatchCase = False
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
.Execute
End With
End Sub
Regards,
Al