Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Removing the menu toolbar from an MSAccess database

Posted on 2014-03-11
6
Medium Priority
?
344 Views
Last Modified: 2014-03-25
Hi all,


This is perhaps an easy question but one that I am trying to implement.

I have several different databases running with simple password forms at the beginning. These as you can imagine can be bypassed. But I was wondering whether there is a way of removing the Access menu bar which allows the user to unhide the database and therefore get access to the different objects.

I know this is not perhaps the ideal solution for a password protected database but in my case it goes a long way.

Thanks
0
Comment
Question by:PipMic
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 48

Expert Comment

by:Dale Fye
ID: 39921851
What version of Access are you using?
0
 

Author Comment

by:PipMic
ID: 39921877
2003


:)
0
 
LVL 48

Expert Comment

by:Dale Fye
ID: 39922304
Sorry,

Don't have a box running 2003 at the moment and cannot remember how to do it.  

But you might try:

Private Sub Form_Open(Cancel As Integer)
    Application.CommandBars("Menu Bar").Enabled = False
End Sub

Don't forget to re-enable that somewhere in your code.
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 

Author Comment

by:PipMic
ID: 39925001
hi Dale,

the code works a treat but I've been reading around and some say that that kind of coding should not be used because it locks the entire programme down!!!
0
 
LVL 48

Accepted Solution

by:
Dale Fye earned 500 total points
ID: 39925069
That is why I said to re-enable that commandbar when you close your application.

I hide the Office 2007/2010 ribbon with a similar technique in all my applications.

As long as you have good error handling, and have a way to restore the commandbar, you should not have a problem.

Worst case open the database with the Ctrl-Shift to bypass any startup form or autoexec.  Then hit Ctrl-G to open up the VB Editor and type:

Application.CommandBars("Menu Bar").Enabled = True

In the immediate window.
0
 

Author Closing Comment

by:PipMic
ID: 39952927
Thanks..does the trick

Apologies for the delay
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question