running database window minimized

toddbingham

Registered User.
Local time
Today, 11:11
Joined
Jul 8, 2003
Messages
93
How do I have the database window startup minimized?

Todd
 
One way is to deselect it from the Startup options.

From the menu bar, click Tools, Startup... and deselect the Display Database Window Option.

Be careful with the deselecting of these options for you might lock yourself out of some thing. If so, you can hold down the Shift key when opening up the db to bypass the startup options.

Also, any changes to the startup options will not take effect until the next time you open the db.
 
'The below code will disable (hide) all menu bars and tool bars.
'Ensure that you have a way to enable (unhide) the menu bars
'and tool bars (transparent command button) before you hide them!

'this will disable all menu bars and tool bars
Dim i As Integer
For i = 1 To CommandBars.Count
CommandBars(i).Enabled = False
Next i

'this will enable all menu bars and tool bars
Dim i As Integer
For i = 1 To CommandBars.Count
CommandBars(i).Enabled = True
Next i

'An added bonus is the right click option is disabled if the menu bars are disabled with the above code.

'Use the 'ShowToolbar' command if you need to display a tool bar or menu bar...
DoCmd.ShowToolbar "YourToolBarNameHere", acToolbarYes

'This will hide a tool bar or menu bar when needed...
DoCmd.ShowToolbar "YourToolBarNameHere", acToolbarNo

'This will hide the Menu Bar...
DoCmd.ShowToolbar "Menu Bar", acToolbarNo

'You can also hide/unhide the database window with code...

'Hide the database window
DoCmd.SelectObject acTable, , True
DoCmd.RunCommand acCmdWindowHide

'Unhide the database window
DoCmd.SelectObject acTable, , True

'Visit this link to see how I disable the Shift key [from within the db] using VBA...
Disable the AllowBypassKey property

Visit this link for more tricks...
Hide all Access Toolbars and Menubars

'HTH
 
Last edited:
To start with the database window not visible:

Tools>Startup

uncheck "Display Database Window"

To minimize database window at startup:

DoCmd.SelectObject acForm, "MyForm", True
DoCmd.Minimize


Where "MyForm" is replaced by the name of the form you want to open the db with.
 

Users who are viewing this thread

Back
Top Bottom