

July 17, 2018

Hi,
I use the following code to filter a table based on cell values in field 2 that ="yes", it was working but now it just flickers rapidly as if filtering then unfiltering.
I am sure its something simple but I can't see it
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.CountLarge > 1 Then Exit Sub
If Not Intersect(Target, Worksheets("ListToFilter").Range("F1")) Is Nothing Then
With ActiveWorkbook.Worksheets("ListToFilter").ListObjects("Table110")
.AutoFilter.ApplyFilter
End With
End If
End Sub


July 17, 2018

Turns out that that code snippet only works if the table is already filtered, in this case a column is filtered on ="Yes" if I clear the filter I get the above result.
But if I apply the filter then change the value in F1 (which can change the "Yes" column) the table does refilter as expected.
regards
John
1 Guest(s)
