When Microsoft Access opens, the first object that opens up by default is the database window. Most of the time you would not like to give your users access the this window, so you can hide this and display your own form or switchboard.
To enable you to show your own Microsoft Access form when the database opens you should create an unbound form and use the Access Start Up options to set this form to open up whenever the database is started.
Below shows a finished Microsoft Access start-up form in form view:
Typical example of an Access Start-Up form.
When designing the form you can set many of the properties that you require. The above has the following properties set:
Once you have decided upon the form design, and altered any properties that you require, you can then set the start-up options. To do this:
Go to the Tools menu, and choose StartUp and you will see the following start-up options dialog box:
Start-Up Options Dialog Screen.
In the Display Form/Page drop down list, select the form that you want to display whenever your database is opened.
Here you can also set further Microsoft Access options such as the Application Title and setting the Database Window to be hidden at Start-up.
To set the options that will close the Start-Up form after a specified length of time, you will need to apply some code to the forms Timer event. You will also need to set the length of time that the form will be display for:
Showing the On Timer event and period that the screen is displayed
for.
In the example the Timer interval is set to 10000 milliseconds which is 10 seconds.
Private Sub Form_Timer() 'On the forms timer event close the start-up form DoCmd.Close acForm, "frmStartUp" 'Open up the main switchboard form when the start-up form closes DoCmd.OpenForm "frmSwitchboard" End Sub
This above code causes the Start-Up form to close after 10 seconds and then opens up your main switchboard form.
In the example database that is available for download, the database has also been hidden. To unhide this press F11 or choose Window » Unhide.
Please download the Microsoft Access 2000 example file from the Microsoft Access Forms page or from the Microsoft Access Downloads index.