Need to disable a menubar command

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a way to disable a menubar command. Specifically, I need to disable the EDIT > DELETE RECORD command.

The application I've developed will physically delete a record using a custom button under VB control. this is necessary because deleting a record in this application could affect several tables

Thanks
Rich
 
I would actually provide a custom menu bar..and then make the edit->delete
record run your custom code (this is actually what I do!). Then, you don't
have to train your users. (or get support calls as to why the delete record
option disappeared...and make your users angry).

You can generally display a command bar via:

CommandBars("menu bar").Controls("records").Controls("refresh").Visible
= True

So, try something like:

CommandBars("menu bar").Controls("Edit").Controls("Delete
record").Visible = false


If you want to see a few screen shots of menus in ms-access..check these
screen shots..(I also explain why I think menus are great idea).

http://www.attcanada.net/~kallal.msn/Articles/UseAbility/UserFriendly.htm
 
Back
Top