Combo Box on report

tangoman66

Registered User.
Local time
Today, 18:12
Joined
Jan 30, 2004
Messages
98
How do you put a combo box on a report? :confused: I've posted this question before but the answer I got previously won't work and there were no other suggestions :(

Cheers
 
You have forgotten the purpose of a report. A report is a one off view of your information, generally for printing and reading. You would use a combo box on a form as a means of selecting information to save in your database and that is why it won't work on a report - different requirements.
 
I'm making a database for a school and I have a query that filters out the names of people taking a particular subject, obviously I then have a from containing the same data and I need the report to print off class lists. At the minute I have it so that the parameter box needs to have the subject typed into it whereas the person I am making the database for would like the parameter box to be a drop down box with all the subject names to choose from.
 
That's different then.

Build a form with a combo box with all your names in.

When the name is selected, get the form to run a macro or write the code which then opens the report in the view you want.
 
At the minute the form I am using also has a parameter box as this too is based on the query, I can change the query so this doesnt appear but will then adding a combo box on the form work? I know how to create a macro to open a report so that shouldn't be a problem

Cheers
 
If your original form works fine then leave it as it is. Just add a button that takes you to a new form when you want to print it. Your new form can be the one to select the name. Your new form can also be used to print everything or just the individual report you require.
 
I've tried making a separate form but it still won't work, the combo box is setup fine and the button links to the report fine but the report still needs a parameter to be entered despite the fact that it is entered in the combo box
 
I do, it doesn't make a blind bit of difference though as the parameter box comes up regardless of whether or not the form is open
 
Then you're not referencing the control properly. Perhaps it's as simple as a spelling mistake. It's safer to specify the full name too, Forms!MyForm!Mycontrol
 
I have just tried what you suggested and I get the following error message...

The record source '[Forms]![frmReportDialogBox]![cboClassList]' specified on this form does not exist. You mispelled the name, or it was deleted or renamed in the current database. In the form or reports design view, display the property sheet by clicking the properties button and then set the record source to an existing table or query.

I have checked the name of the combo box and the reports record source and I do not see where the problem lies :mad:

Thanks for the help though :)
 
I'm now completely confused as to whether this is a form or a report. I don't understand why a form control has a form combobox as a record source.
 
I have a report and the source is as previously posted. I dont understand the error as it says that it doesn't exist on the form when it clearly does. :mad:

The form I am using is now a dialog box as I have changed the proerties of the form.
 
Use the code builder to get the correct references for the Form and control
 
Its OK, I played around this morning and I sorted it out, I've changed one of my queries and it works now. Thanks for the help you gave anyway :cool:
 

Users who are viewing this thread

Back
Top Bottom