How do I delete material that I have highlighted?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I've highlighted (in yellow) material that I want to delete from a text I've
created in Word (Windows NT). Can I delete it without going through the
entire document again to remark the text and hit the delete key?
 
If you wanted everything that is highlighted deleted, then you could use
Edit>Replace>More>Format.

Put your cursor in the find what field and then click the "highlight" option
on the format submenu.

Leave replace with blank and press replace all.

If you have used multi-color highlighting for other purpose then I believe
you would need to use a macro. If so, post in one of the Word VBA groups.
 
Edit replace > format highlight with nothing.

Leave the find and replace boxes empty - or with a macro

Sub DeleteHighlighted()
Selection.HomeKey Unit:=wdStory
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
'**********************
.Text = ""
.Highlight = True
.Replacement.Text = ""
'**********************
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchAllWordForms = False
.MatchSoundsLike = False
.MatchWildcards = False
End With
Selection.Find.Execute replace:=wdReplaceAll
End Sub


--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
Opinicus said:
Excellent. Many thanks for this. (It's also given me a few
ideas.)


How do you do that little clock-cursor thing?

Have a look at the code for the page

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
Back
Top