Parameter Query from LookUp

Richie2837

Registered User.
Local time
Today, 20:06
Joined
Jan 30, 2007
Messages
88
Hello,

I'm trying to get a report based on a parameter query to work. The report is to view all contacts on the database who have been assigned with a particular "Contact Type" - i.e. client, supplier, volunter etc.

These Contact Types are themselves sourced from a LookUp table. Unfortunately this means that when I run the parameter query it doesn't recognise any contacts as being "client" or "supplier" etc, but does display them when I enter the ID number which has been assigned to those Contact Types - this means that unless I know all "clients" have the ID of "5" etc., the parameter query won't work.

Is there a way around this, which doesn't involve me having to make big changes to the LookUp table and associated relationships?
 
Use a form and a combo box to select the client you wish and use the builder in the query's criteria to set the reference to the combo box.
 
Hi Bonb,

I've created a form with a combo box to choose the client type, and think I've correctly used builder in the query to reference the selected client on the form, but can't get it to work. Could you talk me through with some more detail to see where I've gone wrong?
 
Can you post a screenshot of your query in the window with the builder opened? Also, are you keeping the form open when running the query? It will need to be open.
 
I've placed a command button attached to a macro on the form to run the query.
 

Attachments

  • Untitled - 1.jpg
    Untitled - 1.jpg
    91.7 KB · Views: 157
You selected the wrong item. You don't select the field, you would select Combo0 from the list (although I would rename the combo with a meaningful name before doing the selection so that when you, or someone else later on, come back months or years later you would know what it is without major investigation).
 

Users who are viewing this thread

Back
Top Bottom