display all recods in report (1 Viewer)

deekras

Registered User.
Local time
Today, 20:56
Joined
Jun 14, 2000
Messages
169
i have a form where the user can select which category to display in report. how can i set it up for the user to select one category or all categories for the report?
 

doulostheou

Registered User.
Local time
Today, 14:56
Joined
Feb 8, 2002
Messages
314
Just base the report off of a query that links to the form where they select the category. You can write the criteria in the query to pick the selected category or to run normally if the field is left null (select all categories). I believe the syntax you would write in the criteria of your query is below:

Like IIf(IsNull([Forms]![Form]![Category]),"*",[Forms]![Form]![Category])
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 15:56
Joined
Feb 19, 2002
Messages
43,426
If it is possible for category to be null, the above method will not return all records. You need to use the following:


Where Category = [Forms]![YourForm]![Category] or [Forms]![YourForm]![Category] Is Null;
 

Users who are viewing this thread

Top Bottom