That would be contra the purpose AutoFilter was designed for. IOW, it
will only select/include according to your specified criteria. To
accomplish this with VBA would be easy as hiding all rows that contain
the value you want to exclude. (This has nothing to do with using
AutoFilter)...
Sub FilterExcludedData()
Dim vDataIn, n&
Const sExcludes$ = "10125014,11394750" _
& ",223400120,
2234600120" _
& ",52039100,52080100,54004912,54004916"
vDataIn = Range("A1", Cells(Rows.Count, 1).End(xlUp))
For n = LBound(vDataIn) To UBound(vDataIn)
If Len(vDataIn(n, 1)) Then
If InStr(1, sExcludes, vDataIn(n, 1)) > 0 Then _
Rows(n).Hidden = True
End If
Next 'n
End Sub
..wherein colA is assumed to contain the values you want to filter on.
Empty cells are ignored. You can modify this to toggle the filter
and/or prompt the user for the exclude values.
--
Garry
Free usenet access at
http://www.eternal-september.org
Classic VB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion