ComboBox opens before report loads

D

Donna

I have a report that the user can run by choosing an instructor name. I have
created a combo box that lists instructors & have designed the query that
runs the report with the combo box selection as the parameter value. I coded
the report to open the instructor name combo box form on load. I've also
tried it on activate. Either way, the parameter error box shows up before I
get a chance to have the form open & give the user an opportunity to select a
name. What am I doing wrong?
 
K

Ken Snell [MVP]

No, you want to open the form that has the combo box first. Let the user
select the item desired, and then have the user click a command button on
that form to run the report. That button should then open the report.
 
L

Larry Linson

Try opening the Report from the Form with a DoCmd.OpenReport, instead.

Larry Linson
Microsoft Access MVP
 
L

Larry Linson

... I coded the report to open the
instructor name combo box form
on load. . . . What am I doing wrong?

The only event, AFAIK, from which you can successfully modify the
RecordSource of the Report is Open, which you did not mention trying. Still,
see my other response.
 
D

Donna

DUH!
Thanks!

Ken Snell said:
No, you want to open the form that has the combo box first. Let the user
select the item desired, and then have the user click a command button on
that form to run the report. That button should then open the report.
 
M

Michelle Lee

can you tell me how do you code the query to use the combo box selection as
the parameter value? i have a form with a combo box and a print command
button. so that when the user select the value from the combo box, it prints
out a report with data that's related to the value selected. please help.
thanks.

cheers,
michelle
 

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