D
David Frick
I have a form that displays a report in Print Preview view when a command
button is clicked.
The records dispalyed in the form are filtered by a WHERE clause that is
specified by a user's selection in a combo box.
The code in the VB module looks like this:
stDocName = "rpt_Customers"
Cmd.OpenReport stDocName, acPreview, , "StateID = " & Me.[cboStateID]
This returns all the customers from the state selected in the combobox.
But I want to allow the user to select cuistomers from _more than one_
state.
I can allow multiple selects from a listbox but I am not sure how to code
the criteria in my VB module.
This is what I would like to do but does not work:
Cmd.OpenReport stDocName, acPreview, , "StateID IN " & Me.[lstStateID]
Can someone help me with the syntax?
Thanks
Dave
button is clicked.
The records dispalyed in the form are filtered by a WHERE clause that is
specified by a user's selection in a combo box.
The code in the VB module looks like this:
stDocName = "rpt_Customers"
Cmd.OpenReport stDocName, acPreview, , "StateID = " & Me.[cboStateID]
This returns all the customers from the state selected in the combobox.
But I want to allow the user to select cuistomers from _more than one_
state.
I can allow multiple selects from a listbox but I am not sure how to code
the criteria in my VB module.
This is what I would like to do but does not work:
Cmd.OpenReport stDocName, acPreview, , "StateID IN " & Me.[lstStateID]
Can someone help me with the syntax?
Thanks
Dave