Parameter

H

Hong

Hi, I created a parameter form for report.
The parameter form: frmSupplier
1.Combo box: supplier - cboSupplier
2.Command button: OK.
Code: private sub OK-Click()
Me.Visible = False
End Sub

3.Command button: Cancel
Code: private sub Cancel-Click()
DoCmd.Close 'Close Form
End Sub

When I click OK, it's runs the report.

But when I click on the Cancel, it close the form, but also show up the
access window:
Enter parameter value!
form!frmsupplier!cboSupplier

I learned all the code from this group.
Thanks to everybody!
 

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