Excel 2007 VBA - Disable "Exit" Command

D

da_gl

Historically you could disable the "Exit" command using the
following:

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

Any ideas how to do this in Excel 2007?
 
J

Jim Rech

If you're referring to "Exit Excel" on the Office menu, I believe it's
impossible. Strong words, I know, but I've spent a lot of time trying to
disable the Office menu and/or parts of it with little success.

--
Jim
| Historically you could disable the "Exit" command using the
| following:
|
| Application.CommandBars("Worksheet menu
| bar").Controls("File").Controls("Exit").Enabled = False
|
| Any ideas how to do this in Excel 2007?
|
 

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

Top