VBA Question on Toolbars

  • Thread starter Thread starter Steve
  • Start date Start date
S

Steve

HYCH

Is there a way of disabling the Tools Option on the menu bar with VBA?



Steve
 
You can try something like:

Application.CommandBars("Worksheet menu bar").Controls("Tools").Enabled = False

and later to toggle it back:
Application.CommandBars("Worksheet menu bar").Controls("Tools").Enabled = True

It'll be effective until the user resets the toolbar.
 
You can try something like:

Application.CommandBars("Worksheet menu bar").Controls("Tools").Enabled = False

and later to toggle it back:
Application.CommandBars("Worksheet menu bar").Controls("Tools").Enabled = True

It'll be effective until the user resets the toolbar.

thanks dave,

should be fine, users are novices with pc,

so this will suffice


Steve
 
I like to add this to Dave's answer

If you also have users that use Non English versions of Excel use this.

Application.CommandBars("Worksheet Menu Bar").FindControl(ID:=30007).Enabled = False
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Range Question ?? 2
Clearing unlocked cell contents macro 5
comments in a cell 6
Adding via a textbox 4
Worksheet Changes 4
Number formats 1
Range query 5
macro to record keystrokes ? 4

Back
Top