You may want to control the availability of a toolbar button while your application is running, to prevent the user from clicking the button at inappropriate times. To do this, you can dynamically enable and disable the toolbar button. When a toolbar button is disabled, it beeps when it's clicked and doesn't run the procedure associated with it. The Enabled property sets or returns the state (enabled or disabled) of a toolbar button.
The following example disables button three on the Standard toolbar.
Toolbars("Standard").ToolbarButtons(3).Enabled = False