Change the availability for the shortcut menus
2000-02-05 Commandbars 0 203
The macro below shows how you can toggle the availability state for the shortcut menus.
Sub ToggleCommandBars() Dim cbEnabled As Boolean cbEnabled = Not CommandBars(25).Enabled CommandBars(25).Enabled = cbEnabled ' shortcutmenu for cells CommandBars(26).Enabled = cbEnabled ' shortcutmenu for columns CommandBars(27).Enabled = cbEnabled ' shortcutmenu for rows CommandBars("Toolbar List").Enabled = cbEnabled ' shortcutmenu for toolbars End SubThe CommandBar Tools available for download will help you to find the names and ID numbers of the available CommandBars.