Anthony
Tue Jan 06 17:58:49 CST 2004
Yes Jonathan - thanks. I posted the code as a follow-up. But I got it
figured out. What I did was assign a keyboard shortcut (overwriting F5 in
this case) to turn on highlighting. For some reason I could not get macro
recorder to record the keystroke either. So I manually entered it using the
VB editor and came up with this:
Options.DefaultHighlightColorIndex = wdPink
SendKeys "{F5}"
I made five of these and put colored icons on my taskbar next to the
highlighter button. I also made one for removing highlighting. To wit:
Options.DefaultHighlightColorIndex = wdNoHighlight
SendKeys "{F5}"
This works fine. I still can't figure why a simple
"Options.DefaultHighlightColorIndex = wdPink" should shut the highlight off.
Seems strange, since I did not include any command to shut it off.
Thanks again.
--
Regards,
Anthony Giorgianni
The return address for this post is fictitious. Please reply by posting back
to the newsgroup.
"Jonathan West" <jwest@mvps.org> wrote in message
news:%23bz6LcK1DHA.2868@TK2MSFTNGP09.phx.gbl...
> Could you show us the code you have produced so far? That would make it
> easier to reproduce the problem and see what needs to be added.
>
> --
> Regards
> Jonathan West - Word MVP
>
http://www.multilinker.com
> Please reply to the newsgroup
>
> "Anthony Giorgianni" <pleasepostbacktothegroup@postbacktogroup.invalid>
> wrote in message news:%23p15jGK1DHA.2328@TK2MSFTNGP10.phx.gbl...
> > Hello All
> >
> > In Word 2000, I routinely need to use different highlighter colors
within
> > the same document and thought I would create a macro to be able to
change
> > the highlighter color quickly without having to use the color pull-down
> > menu.
> >
> > I have been successful except for one thing: When I click on the macro
> > button I created on the toolbar, the highlighter color changes as I want
> BUT
> > the highlighter then turns off for some reason. That means I then have
to
> > move the cursor over to the highlighter button and click it to turn the
> > highlighter back on - an annoying second step. If I try to incorporate
> this
> > step into the macro, it does not accept it. In fact, recording a macro
> that
> > ONLY turns the highlighter on appears not to work.
> >
> > Is there a shortcut key combination or some other bit of code I can add
to
> > my color-change macros to ensure that the highlighter either does not
turn
> > off or is turned back on after the color is changed?
> >
> > Thanks.
> >
> >
> > --
> > Regards,
> > Anthony Giorgianni
> >
> > The return address for this post is fictitious. Please reply by posting
> back
> > to the newsgroup.
> >
> >
>