I would like to populate a string variable 'x' with the current value of Criteria1 for field #2 of the autofiltered range of the current sheet.
I think I'm looking for a simplified version of this but I cannot work out how to simplify it.
The filtered table will always have headers in row 10, data is in columns A:Z, and I only care about the criteria1 and criteria2 values for column B (field #2). The filter criteria will always be strings (not arrays or dates).
Sub CycleFilterSettingsFieldTWO()
Dim x As String
x= ActiveSheet.AutoFilter.field(2).criteria1 'best guess, doesn't work!
'I've also tried ...
'activesheet.autofilter.filters.filterarray(10,2)
'activesheet.autofilter.filters.item(1,1)
Select Case x
Case Is = "3"
ActiveSheet.AutoFilter.Range.AutoFilter field:=2, Criteria1:="4"
Case Is = "4"
ActiveSheet.AutoFilter.Range.AutoFilter field:=2, Criteria1:="*" 'Show everything
Case Else
ActiveSheet.AutoFilter.Range.AutoFilter field:=2, Criteria1:="3"
End Select
End Sub