Filter listbox by Multiple Combos (1 Viewer)

oihjk

Registered User.
Local time
Today, 05:43
Joined
Feb 13, 2003
Messages
51
I've got a list box that I want to filter by Year, Month and Day of Month. I would prefer using combos containing the values I want to filter by.

In the recordsource of the listbox I'm using the Format([Date],"yyyy") method to get the year, month and day of month.

1. I want to be able to select the Year and have the listbox show only values from that year. I can do that by putting [forms]![frmSearch]![cmbYear] in the criteria.
2. Next I want to select the month then have the listbox display only the records from the selected year and month.
3. Then select Day of month and filter listbox by all three.
- or -
1. Select a value from any of the three combos and filer by that selection.

I've tried:

is null
[forms]![frmSearch]![cmbYear]

empty
is null
[forms]![frmSearch]![cmbMonth]

empty
empty
is null
[forms]![frmSearch]![cmbDOM]

doesn't seem to work.
 

Users who are viewing this thread

Top Bottom