How do I delete material that I have highlighted?

J

jhm

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?
 
G

Greg Maxey

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.
 
G

Graham Mayor

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


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
G

Graham Mayor

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


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
G

Graham Mayor

Greg said:
Please No!!

I nearly mentioned your love of the clock in my reply ;)

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


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top