Re: How to disable (gray out) a button on the toolbar?

Tech-Archive recommends: Fix windows errors by optimizing your registry




Ale wrote:
> Usually a toolbar button has the same ID of Menu item...
> ON_UPDATE_COMMAND_UI() will apply on both Menu and Toolbar throw the
> framework...

Thanks a lot! That got it working perfectly.

And let me add, for the lurkers out there - VC++ .NET doesn't have the
same nice right-click "Add Event Handler" for toolbar buttons as it
does for menu options, but if you just use the added code for menu
options as a template and adjust the ID appropriately it will work.

.


Quantcast