I am attempting to filter a dataview with the use of a Date Range. I am using two different DateTimePicker controls (dtpStartDate and dtpEndDate)
Here is the code I am using:
Dim _sDateRangeFilter as String
_sDateRangeFilter = "dOrderDate > " & dtpStartDate.Value.Date & " AND < " & dtpEndDate.Value.Date & ""
When I pass this value to my dataview.rowfilter I am getting this error:
Syntax error: Missing operand before '<' operator.
I've tried adding the "#" in the appropriate places, but get the same error.
I also tried using a "BETWEEN" operand but got an error indicating that that was not a valid operand.
Any help is greatly appreciated.
Thanks!
Brian
Here is the code I am using:
Dim _sDateRangeFilter as String
_sDateRangeFilter = "dOrderDate > " & dtpStartDate.Value.Date & " AND < " & dtpEndDate.Value.Date & ""
When I pass this value to my dataview.rowfilter I am getting this error:
Syntax error: Missing operand before '<' operator.
I've tried adding the "#" in the appropriate places, but get the same error.
I also tried using a "BETWEEN" operand but got an error indicating that that was not a valid operand.
Any help is greatly appreciated.
Thanks!
Brian