R
RMoore2764
I am running into a problem I have never seen before when using a Loo
process. My macro is looping thru approx 1000 rows and if criteria i
correct it deletes the row. However it appears to miss several row
that should be deleted but aren't. I have to run loop several time
(up to 10) to get all. My assumption is that if loop is slowed dow
all would be picked up. Any thoughts or ideas would be greatl
appreciated. Here is code I use:
Row = 2
Do Until (Cells(Row, 2).Value = "")
Sheets("PHO").Cells(Row, 1).Select
If (Sheets("PHO").Cells(Row, 1).Value <> "8") Then
Selection.EntireRow.Delete
End If
Row = Row + 1
Loop
Thanks,
Ro
process. My macro is looping thru approx 1000 rows and if criteria i
correct it deletes the row. However it appears to miss several row
that should be deleted but aren't. I have to run loop several time
(up to 10) to get all. My assumption is that if loop is slowed dow
all would be picked up. Any thoughts or ideas would be greatl
appreciated. Here is code I use:
Row = 2
Do Until (Cells(Row, 2).Value = "")
Sheets("PHO").Cells(Row, 1).Select
If (Sheets("PHO").Cells(Row, 1).Value <> "8") Then
Selection.EntireRow.Delete
End If
Row = Row + 1
Loop
Thanks,
Ro