Article ID: 204061
Article Last Modified on 1/23/2007
expression.AutoFilter(Field, Criteria1, Operator, Criteria2, Visibledropdown)
Argument Description
----------------------------------------------------------------------
Field The integer offset of the field on which you want to
filter the list (the first field in your list has a
value of 1)
Criteria1 The criteria for filtering the specified field
Operator Used to construct compound criteria
Criteria2 Used in conjunction with Criteria1 and Operator to
build compound criteria
Visibledropdown True or False; false hides the drop-down list for the
specified field
A1: Name B1: Area C1: Amount
A2: Bob B2: East C2: 1
A3: Sue B3: West C3: 2
A4: Bill B4: East C4: 3
A5: Mary B5: South C5: 4
Sub Hide_Dropdown()
'Apply an AutoFilter to the list and hide the drop-down list
'for the second field.
Range("A1").AutoFilter field:=2, Criteria1:="East", _
Visibledropdown:=False
End Sub
A1: Name B1: Area C1: Amount A2: Bob B2: East C2: 1 A4: Bill B4: East C4: 3There is no drop-down list for the Area field.
Additional query words: MacXLX Max XLX XL2001 XL98 auto filter auto-filter drop down vba
Keywords: kbcode kbinfo kbprogramming tp_cs KB204061