Sort Field or Not Sort Field

  • Thread starter Thread starter protean_being
  • Start date Start date
P

protean_being

I have a form that contains a check box called chkPrimaryLocation and a combo
box called cboPrimaryLocation. This form is an entry page that runs a query
to generate a report. What I want to do is to uncheck the box if I want to
see all non null fields and check the box if I want to see only the selected
location in the combo box.
How do I define the criteria for PrimaryLocation in the query to make this
work?
 
Criteria for PrimaryLocation --
Like IFF([Forms]![YourFormName]![chkPrimaryLocation] = 0, "*",
[Forms]![YourFormName]![cboPrimaryLocation])

In neither case will you records that location is null.
 
Criteria for PrimaryLocation --
Like IFF([Forms]![YourFormName]![chkPrimaryLocation] = 0, "*",
[Forms]![YourFormName]![cboPrimaryLocation])

In neither case will you records that location is null.

minor typo, Karl - I'm sure you meant IIf (not IFF).
 
Back
Top