Filter Question with condition

  • Thread starter Thread starter a
  • Start date Start date
A

a

Thank you
I have form with command button and 2 textbox (Bdate1) and (Edate2) not
bound to any fields
And I have one field name (ADates)
ADates Data
1/1/2003
2/1/2004
3/1/2004
5/1/2004
6/1/2004
7/1/2004
Question:
I want the code to filter ADates using 2 textbox (BDate1) and (EndDate2)
with command button?
This is what I Find:
Me.Filter = "alldates = between #" & Me. Bdate1 & "#" and #"&me. Bdate1 &
"#"
And this code not work:
I hope you can answer
 
a said:
Thank you
I have form with command button and 2 textbox (Bdate1) and (Edate2) not
bound to any fields
And I have one field name (ADates)
ADates Data
1/1/2003
2/1/2004
3/1/2004
5/1/2004
6/1/2004
7/1/2004
Question:
I want the code to filter ADates using 2 textbox (BDate1) and (EndDate2)
with command button?
This is what I Find:
Replace code with this:
Private Sub cmdButton_Click()
Filter = "alldates = Between #" & BDate1 & "# and #" & EndDate2 & "#"
FilterOn = True
End Sub
 
You are using = with between ... and ...

You should drop the =

Filter = "alldates Between #" & BDate1 & "# and #" & EndDate2 & "#"
 
Back
Top