Hello!
I'm looking to delete all rows not containing the following in column E. I have the following code, but it's not working. Any ideas?
Thanks!
I'm looking to delete all rows not containing the following in column E. I have the following code, but it's not working. Any ideas?
Code:
With ActiveSheet.UsedRange
.AutoFilter field:=5, Criteria1:=Array("<>PN", "<>RN", "<>DR", "<>TA"), Operator:=xlFilterValues
.Offset(1, 0).SpecialCells(xlCellTypeVisible).EntireRow.Delete
End With
Thanks!