View Single Post
 
Old 12-04-2011, 01:08 AM
tinfanide tinfanide is offline Windows 7 64bit Office 2010 32bit
Expert
 
Join Date: Aug 2011
Posts: 312
tinfanide is on a distinguished road
Default Word VBA: assign shortcut keys to sub???

Code:
Sub textHighlighter()

Selection.range.HighlightColorIndex = wdYellow

End Sub
I want to assign shortcut keys to this sub
when I highlight texts, just press the key to do the effect

I have tried
Code:
Application.OnKey "', ""
But doesn't work at all.
I mean thru VBA, not thru using the Macro Menu.
Thanks in advance.
Reply With Quote