S
sarah
I want to underline text and change the colour of the underline.
I am able to underline it but i cannot color it.
Here is my code.
With ActiveDocument.Range.find
.Text = errortxt
.MatchWholeWord = True
.Replacement.Font.Underline = wdUnderlineWavy
.Replacement.Font.underlinecolor = wdColorRed
.Execute replace:=wdReplaceAll
End With
if i use activedocument.range.find.font.underlinecolor = wdcolorred after
the with block it just changes the colour of all the underlined text in the
document
What am i doing wrong?
I am able to underline it but i cannot color it.
Here is my code.
With ActiveDocument.Range.find
.Text = errortxt
.MatchWholeWord = True
.Replacement.Font.Underline = wdUnderlineWavy
.Replacement.Font.underlinecolor = wdColorRed
.Execute replace:=wdReplaceAll
End With
if i use activedocument.range.find.font.underlinecolor = wdcolorred after
the with block it just changes the colour of all the underlined text in the
document
What am i doing wrong?