"Hi
I want to delete all rows in my table if Column I is 99. The below code give in and runtime error 1004 AutoFilter method of Range class failured
The 99 is a number not text, so I also tried 99 instead of "99" but got the same error. Could it be because it is a table ? If so how can I fix it.
Worksheets("Data").Activate
With ActiveSheet
.AutoFilterMode = False
With Range("I1", Range("I" & Rows.Count).End(xlUp))
.AutoFilter 1, "99"
On Error Resume Next
.Offset(1).SpecialCells(12).EntireRow.Delete
End With
.AutoFilterMode = False
End With
Thanks
L
I want to delete all rows in my table if Column I is 99. The below code give in and runtime error 1004 AutoFilter method of Range class failured
The 99 is a number not text, so I also tried 99 instead of "99" but got the same error. Could it be because it is a table ? If so how can I fix it.
Worksheets("Data").Activate
With ActiveSheet
.AutoFilterMode = False
With Range("I1", Range("I" & Rows.Count).End(xlUp))
.AutoFilter 1, "99"
On Error Resume Next
.Offset(1).SpecialCells(12).EntireRow.Delete
End With
.AutoFilterMode = False
End With
Thanks
L