Query Problem

K

Kerry

Hi

I have a form which is based on a query which has 5
fields, I want to be able to search on 4 fields by
dropdown boxes on a form,

for example

Combo 1 = Yes
Combo 2 = No
Combo 3 = Nothing selected
Combo 4 = Nothing selected

I want me query to automatically pick up all records which
have Combo 1 as YES *or* combo 2 as NO, with anything in 3
and 4. (BUT !) it has to be flexible enough to handle
Combo3 with YES And the rest as no selected or any
combination as above ! I am going round in circles and all
to no avail !!!

Hope you can throw light on this !!
Its starting to do my head in
 
M

Marty

In the QUERY Criteria section, right click, click BUILD.
Double click FORMS > ALL FORMS. Select the form with the
combo boxes. In the middle section of this dialog box you
should see your combo box name "COMBO1", double click it
and it will be added to the criteria section of this
dialog box. Click OK. Now, what the users chooses from
this combo box will be the look up criteria. One thing to
note however: If the user chooses criteria in "COMBO1"
that's true but chooses criteria in any or all the other
combo boxes that is not true the query will return no
records. If you want to return records if any of the
combo boxes choices are true, repete the above
instructions in the OR field (just below the CRITERIA
field).
 

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