JugglerJAF
Active Member
- Joined
- Feb 17, 2002
- Messages
- 297
- Office Version
- 365
- Platform
- Windows
I was recently given the following code to disable the Share Workbook menu:
Probably a massively newbie question but how do I list/find out the ID numbers of other menu items (either top level, eg File. Main menu level, eg Print Area. Or sub-menu, eg Clear Print Area).
I have a number of menu items in a particular spreadsheet that I need to disable to stop certain individuals from "breaking" the spreadsheet. Simply protecting the sheet doesn't work for everything (users can still clear or reset a print area).
JugglerJAF
Code:
Sub DisableShareWorkbookButton()
Application.CommandBars.FindControl(ID:=2040).Enabled = False
End Sub
I have a number of menu items in a particular spreadsheet that I need to disable to stop certain individuals from "breaking" the spreadsheet. Simply protecting the sheet doesn't work for everything (users can still clear or reset a print area).
JugglerJAF