Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linking Queries and Reports

Status
Not open for further replies.

DawnC

Programmer
May 14, 2003
2
US
I am setting up a database for organizing customer complaints, survey responses, nonconformances, etc. and I have just enough knowledge of Access to be dangerous. I'm working with Access 2000 and I've got myself stuck.

I have already set up all my tables, the forms to enter data for the tables (this database will be used by multiple people) and the queries to get the specific data out for specific tasks. The queries are run by forms (using a combo box and button) with drop-down menus identifying the criteria. Again, I'm trying to make this as idiot-proof (and with as little entry typing) as possible.

Where I've run into problems is getting the queried info to link to a report (I will end up having many and they will be task-specific).

I know how to make a report that is linked to a simple parameter query. When you go to generate the report, it prompts you for the criteria (just like the query would if you ran the query by itself). The problem I am getting is that when I try to run the report, it prompts me for the criteria like the simple parameter query. However, instead it states the actual criteria for the combo box which is something like: FORMS![Name of Query]![Name of Combo Box]. And this is what shows up on the parameter query when I run the report (in place of "Enter...").

I know there has to be a way to do this, but I can't find it through the Access help option. I don't think I'm wording the request right. Can I either make the report to prompt for the criteria using the dropdown boxes or is there another way run the query and have the queried data just "appear" in the correct report format (I know that I'm simplifying this way too much...please bear with me).-

Anyway, any help would be GREATLY appreciated!!!!:-}

Thanks!
 
in the criteria of your query you need to place an expression similar to:
FORMS![Name of Query]![Name of Combo Box].

where [name of query] is the name of your form and
[Name of Combo Box] is the name of the combo box with the criteria in.

I hope I have understood the Q properly.

Nick
 
Also, your form must be open so the report can find FORMS![Name of Query]![Name of Combo Box] - it will prompt for that if the form is closed, the name is misspelled, etc.
 
Thanks, I'll see what I can do first thing Monday morning...I appreciate the help!!!!

Dawn
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top