I using the Autofilter method and I would like to change to using the loop function, as it might be faster? I have anywhere from 25,000-30,000 rows..
Trying to get Delete rows if the cell in columns C contains "Pending"
My code kinda works, but it misses a few...
Another request, if possible, can I modified this to if the cell contains a date?
Trying to get Delete rows if the cell in columns C contains "Pending"
My code kinda works, but it misses a few...
VBA Code:
Sub LoopCells()
Dim cell As Range, Pending As Range
Set Pending = Range("C2:C" & Cells(Rows.Count, "C").End(xlDown).Row)
For Each cell In Pending
If cell.Value = "Pending" Then
cell.EntireRow.Delete
End If
Next cell
End Sub
Another request, if possible, can I modified this to if the cell contains a date?