I have a sheet that contains at least 97000 rows. I'm testing a VBA code to find and delete rows that contain certain word. my problem is that this works fine with fewer number of rows but gets stuck with larger ones.
here is my code:
Is there a better and faster way to do it?
what if I wanted to combine conditions like deleting rows that contain either "Recover" or "NR"?
thanks
here is my code:
Code:
Application.ScreenUpdating = False
Application.StatusBar = "Cleaning up, please wait.."
Do While True
Set c = Cells.Find(What:="Recover")
On Error Resume Next
If c Is Nothing Then Exit Do
c.EntireRow.Delete
Loop
Application.ScreenUpdating = True
Application.StatusBar = False
Is there a better and faster way to do it?
what if I wanted to combine conditions like deleting rows that contain either "Recover" or "NR"?
thanks