G
gr
Hello!
hi, i'm trying to apply a filter on a form depending on a
criteria comming from a cbo box.
My syntax looks like this but is not working at all
(doesn't filter, finds no match even when there is)
strFilter = "[Forms]![frmMD]![sfrmMeasurementDevices].
[Form]![SubCatID].Column(1) Like " & Me!cboCategory
If (Me!cboCategory <> "(All)") Then
Me.sfrmMeasurementDevices.Form.Filter = Eval
(strFilter)
Me.sfrmMeasurementDevices.Form.FilterOn = True
Else
....... more code ...
I tried using only
strFilter = "SubCatID.Column(1) Like " & Me!cboCategory
But then I got an "Undefined function error"
Using
strFilter = "SubCatID.Column(1) Like " & Me!cboCategory
Me.sfrmMeasurementDevices.Form.Filter = Eval(strFilter)
Returns a "Can not find Name SubCatID"
Any help will be appreciated.
I got a previous answer about coordinating comboboxes, I'm
not trying to do that just to filter my form. Let me know
if you need more details.
gr
hi, i'm trying to apply a filter on a form depending on a
criteria comming from a cbo box.
My syntax looks like this but is not working at all
(doesn't filter, finds no match even when there is)
strFilter = "[Forms]![frmMD]![sfrmMeasurementDevices].
[Form]![SubCatID].Column(1) Like " & Me!cboCategory
If (Me!cboCategory <> "(All)") Then
Me.sfrmMeasurementDevices.Form.Filter = Eval
(strFilter)
Me.sfrmMeasurementDevices.Form.FilterOn = True
Else
....... more code ...
I tried using only
strFilter = "SubCatID.Column(1) Like " & Me!cboCategory
But then I got an "Undefined function error"
Using
strFilter = "SubCatID.Column(1) Like " & Me!cboCategory
Me.sfrmMeasurementDevices.Form.Filter = Eval(strFilter)
Returns a "Can not find Name SubCatID"
Any help will be appreciated.
I got a previous answer about coordinating comboboxes, I'm
not trying to do that just to filter my form. Let me know
if you need more details.
gr