Filtering with <

  • Thread starter Thread starter owen wilson
  • Start date Start date
O

owen wilson

Hi,

I have a series query that are filtered by the date
generated in a form.

The criteria is <[Forms]![Month Select]![txtrptdate]

There is one query for each month and all return correct
values except the query for the month selected, it
returns a null value.

I am trying to get information for all months prior to
the one selected.

Presently the string that is filtered is a date string
like 1/1/04

Any suggestions will be greatly appreciated

TIA

Owen
 
Presumably this filter is being applied to a field that is a Date/Time field
(not a Text field).

To ensure that Access interprets the date correctly:
1. Set the Format property of the txtrptdate text box to:
Short Date
so Access knows it is a date and won't accept anything except a date.

2. In query design view, explicitly declare this as a parameter. Click
Parameters on the query. Access opens a dialog. Enter:
[Forms]![Month Select]![txtrptdate] Date/Time
 
Back
Top