Filtering By Date

G

Guest

I have a filtering form with two combo boxes, one for the staff member, one
for the dates. The AfterUpdate event of the requeries the second combo to
display only dates matching the selected employee.

I wish to load a second form on the press of a button which displays all
fields matching the entered criteria, but am having trouble with specifying
the criteria for the date field. I'm getting the following results:

Criteria Query
Result
------------------------------------------------------
--------------------------
=Forms![MyForm]![cboMyCombo] No records returned
=DateValue(Forms![MyForm]![cboMyCombo]) Wrong syntax or too complex
to be
evaluated
= #Forms![MyForm]![cboMyCombo]# Wrong syntax or too complex
to be
evaluated
= "#" & Forms![Myform!][cboMyCombo] & "#" Wrong syntax or too complex
to be
evaluated

The date displayed is 10/8/2006. If I enter the criteria as #10/8/06#, the
query returns the right records. If I use the Immediate Window, it says the
value of the combo box is 310.

Can anyone point me in the right direction? Thank you.

Sprinks
 
G

Guest

I solved it; the BoundColumn was set incorrectly.

Thank you to any responders.

Sprinks
 

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