In this post, we will be showing you how to create a simple Switchboard form that you can use to open up forms.
Please download the database to follow along with the post.
How Exactly Do We Create A Switchboard Form
The first thing we need to do is create a blank form and then add a button. Save the form as frmAdmin and name the button cmdSwitchboard.
Click on cmdSwitchboard button and in the property sheet click on the event tab. Click on the ellipsis for the On Click line and choose Macro Builder.
Add “RunMenuCommand” as a new Macro action and type in Switchboard Manager.
Save and close the Macro. Change the Form view to Form mode and click on cmdSwitchboard.
Click on Yes.
This is the form that you will use to create your Switchboard. We will be showing you how to use it to open up data-entry forms.
As it stands, you have one switchboard called “Main Switchboard”. This switchboard doesn’t contain any buttons yet because we haven’t told it what we want it to do.
Click on Edit.
This form lists all of the operations under the Main Switchboard (none). Click on New and let’s add one.
A new form pops up that will allow us to add a single operation.
For Text write Languages. For Command choose Open Form In Edit Mode and for Form choose frmSuppliersDataEntry.
Click on OK. Repeat the same exercise only this time we will add frmLanguagesDataEntry.
Now let’s take a look and see what we have done.
Close all of the dialog boxes associated with the Switchboard Form and open up the Navigation Pane. Find Switchboard and double-click on it to open it up.
If you now click on Suppliers, frmSuppliersDataEntry will open up.
And clicking on Languages will cause frmLanguagesDataEntry to open up.
We are going to add buttons for frmFormDataEntry, frmServicesDataEntry, frmClientsDataEntry and frmSubjectsDataEntry.
Our Edit Switchboard Page dialog box now looks like this…
…and our Switchboard now looks like this…
In this post, you have learned how to create a simple Switchboard Form that can open up other forms in the database. In the next post, we will be showing you how to create different “views” so that you can click on a button and get taken to what appears to be a separate form when it fact it is the same form with a different filter. Spooky!