Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
autofilter with variable criteria
I have the following programming attempting to use the variable CBOX as my
Criteria1 in an autofilter. I get a syntax error on the autofilter line when i run it. The line works fine if I use "=" as opposed to the "<" which i want. I am attempting to filter away the variable in CBOX. ======================== Private Sub CheckBox3_Click() Dim cbox As String Let cbox = CheckBox3.Caption If CheckBox3 = False Then Selection.AutoFilter Field:=40, Criteria1:<cbox Else Selection.AutoFilter Field:=40 End If End Sub ======================== thanks, dr chuck |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Autofilter criteria not yet known | Excel Programming | |||
AutoFilter criteria | Excel Programming | |||
AutoFilter Criteria VBA | Excel Programming | |||
Variable in AutoFilter criteria | Excel Programming | |||
VBA Autofilter Criteria | Excel Programming |