Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / August 2005

Tip: Looking for answers? Try searching our database.

Greying out commands in toolbars and menus (also highlighting commands)

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Sol Apache - 09 Aug 2005 09:51 GMT
I have a few menu and toolbar commands which are macros intended to be used
in tables only. In order that users won't complain that the macro doesn't
work when they click on it outside of a table, can I have such commands
greyed out in both the menus and a custom toolbar?

Also, can I have toolbar items (styles, macros) highlighted when the user is
using them? In some cases they may be using two styles - a paragraph and a
character - so it would be helpful if these highlight when the cursor is in
the document area where the styles are being used. If this is possible for
styles, I'll have to add the styles to a few macros and redo the toolbar for
this to work, but that doesn't matter.

To prioritise my requests, the greying out one is more vital.

Thanks for any help.
Sol Apache - 09 Aug 2005 11:38 GMT
Hello

I should have been more explicit in my original request below. I have
changed ³greying out² to ³Disabling² but I do want the text to be faded out
(grayed) as the inbuilt Word commands are when they are unavailable.

Also I am using Word 2004 on a Mac but my templates are used on PCs.

Thanks

On 9/8/05 09:51, in article BF1E2D3E.4341%Sol@solapache.com, "Sol Apache"
<Sol@solapache.com> wrote:

> I have a few menu and toolbar commands which are macros intended to be used
> in tables only. In order that users won't complain that the macro doesn't
[quoted text clipped - 11 lines]
>
> Thanks for any help.
Klaus Linke - 20 Aug 2005 00:32 GMT
Hi Sol,

In principle, you could write an event handler for the SelectionChange
event, check if the selection is in a table (or formatted in a particular
style), then toggle the buttons.
But not even the MS programmers do that for the built-in controls for styles
(which would be nice especially for character styles)... They probably are
wary of the performance hit and/or the additional complications introduced
by the event handler.

So as Doug Robbins already said in another group, I wouldn't try, but simply
put up a message box if some command doesn't work in some context.

Greetings,
Klaus

> Hello
>
[quoted text clipped - 31 lines]
>>
>> Thanks for any help.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.