Trying to Build a Main Menu form with Command Buttons

B

Boyd

I have a very simple DB; 2 tables with a simple input form for each and a few
reports. The forms and reports run wonderfully. I'm trying to create a
"Main Menu" form with command buttons that open the appropriate form, or run
the appropriate report. I've used the Buttons Wizard to add buttons to the
"blank" form, but when I click on those buttons in Form View, nothing
happens. What am I doing wrong???
 
J

Jeanette Cunningham

Easy way is to create a blank new form in design view.
Add the command buttons you need.
Code for a button like this

Private Sub Form1Button_Click
DoCmd.OpenForm "[NameOfForm]"
DoCmd.Close acForm, Me.Name
End Sub


Note: replace 'Form1Button' with the name of your command button
replace 'NameOfForm' with the name of the form to be opened.



Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top