How do I remove colored highlighting using a keystroke combination

  • Thread starter Rhonda from Western Australia
  • Start date
R

Rhonda from Western Australia

I can't find any keystroke combination that applies or removes colored
highlighting (yellow, green, pink etc.). I have to select text, then click
the Highlight toolbar icon to turn it on and off. CTRL+Space doesn't work to
remove highlighted text - the highlighting remains, and I can't find any
keystroke combination in the standard Tools > Customize window (in fact,
Format in the Commands window doesn't list Highlight that I could see so I
can't even assign a keystroke of my own). The list of shortcut keys in the
Online Help has nothing either.

I'm using Word 2003, but have Word 2007 on another machine. A solution that
works for both would be good!

Thanks
 
O

Opinicus

"Rhonda from Western Australia" wrote
I can't find any keystroke combination that applies or removes colored
highlighting (yellow, green, pink etc.). I have to select text, then click
the Highlight toolbar icon to turn it on and off. CTRL+Space doesn't work
to
remove highlighted text - the highlighting remains, and I can't find any
keystroke combination in the standard Tools > Customize window (in fact,
Format in the Commands window doesn't list Highlight that I could see so I
can't even assign a keystroke of my own). The list of shortcut keys in the
Online Help has nothing either.
I'm using Word 2003, but have Word 2007 on another machine. A solution
that
works for both would be good!

I use this macro:

<quote>
Sub ZapColor()
'
Options.DefaultHighlightColorIndex = wdNoHighlight
Selection.Range.HighlightColorIndex = wdNoHighlight
With Selection.Font
.ColorIndex = wdAuto
End With
End Sub
</quote>

You can assign it to any keystroke combination that's available. It should
work in all current versions of Word.
 
R

Rhonda from Western Australia

Unfortunately, I'm working in a corporate environment that has locked down
the ability to create macros. Sorry, I should have mentioned that initially.
 
D

Doug Robbins - Word MVP

What happens if you press Alt+F11?

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Rhonda from Western Australia"
 
R

Rhonda from Western Australia

Clever! ALT+F11 opened the Macro page, so I was able to add the macro. I then
used the Tools > Customize > Keyboard > Macros (category) to assign a
keyboard shortcut and it worked brilliantly.

Thanks to both of you!!

Though seeing as though Microsoft has the highlight function as a toolbar
icon, it would be nice to be able to assign a key stroke combination in an
easier way...
 
T

Tony Jollans

If you want to do it without using a macro, you can assign a keyboard
combination to the Highlight command. This will toggle the highlighting of
the Selection.

In Word 2003: Tools > Customize > Keyboard button
In Word 2007 > Office Button > Word Options > Customize tab > keyboard
shortcut Customize button

Then, under Categories (on the left) select All Commands
And, under Commands (on the right) scroll down and select Highlight

Assign your key combination of choice.
Word 2007 appears to have a default of Ctrl+Alt+H already assigned.

--
Enjoy,
Tony

www.WordArticles.com

"Rhonda from Western Australia"
 
R

Rhonda from Western Australia

Thank you Tony! That'a exactly what I was looking for but couldn't find. The
toolbar options have Highlight under Format, so that's where I looked under
Customize commands. I didn't think to look under "All commands".

For anyone else doing this, click the Highlight toolbar button to select the
colour first, then use the keybaord assignment you set to turn that colour on
and off.
 
D

Dan Freeman

Opinicus said:
So much for corporate environment lockdowns...
;-)

Corporate lockdowns are often easy to bypass.

A programming course I used to teach included showing how to execute
external programs, and I usually used sol.exe (Solitaire) just for the
humor. Everyone at a large corporate client assured me it wouldn't work
because IT removed games from all the Windows installations.

Turns out they removed the games *group* but not the exes. Word filtered
back to me that custom applications at companies all over Omaha were showing
up with Solitaire on their menus. <g>

Dan
 
D

Doug Robbins - Word MVP

I never believed it.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
 
K

Kamran

The direct keyboard shortcut assigning the built-in Highlight function (from
the All Commands section) works, but only if the Highlight selector is on the
color you already want. If it isn't, it won't do anything. I came up with
this macro to toggle highlights. It checks to see if the selected text has a
highlight, and if it doesn't, it applies Yellow. If it has a highlight, it
removes it. Color can be changed as needed.

If highlighting one word, you don't have to select it; it just highlights
the word where the cursor is sitting (same applies to the regular tool).

Sub Highlight_Toggle()

If Selection.Range.HighlightColorIndex = wdNoHighlight Then
Selection.Range.HighlightColorIndex = wdYellow
Else: Selection.Range.HighlightColorIndex = wdNone
End If

End Sub
 

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