Slow macros cont.....
You don't have to restart.
Type Application.ScreenUpdating = True
in the VBA immediate window and hit return.
Foss wrote:
Hi there,
Have you tried using this:
Application.ScreenUpdating = False
at the start of your macro?
If you use this, YOU MUST add this to the end of the macro.
Application.ScreenUpdating = True
If you don't, you won't be able to use excel until you
restart it. Which is very annoying!
Cheers,
Foss
-----Original Message-----
Hi All
From my original example (see the bottom of the page) I
have replaced
Rows("600:600").Select
Selection.Delete Shift:=xlUp
with
Rows("600:600").Delete Shift:=xlUp
This has helped a considerable amount, however, it zooms
through about 150 to 200 rows then slows again. Excel
2002 is a real pain at the moment.
can any one advise me further
Cheers
Original Example
Sub Delete_Row_600_551()
Sheets("Data").Select
If Range("G600") < Range("Q1") Then
Rows("600:600").Select
Selection.Delete Shift:=xlUp
End If
If Range("G600") Range("S1") Then
Rows("600:600").Select
Selection.Delete Shift:=xlUp
End If
If Range("G599") < Range("Q1") Then
Rows("599:599").Select
Selection.Delete Shift:=xlUp
End If
If Range("G599") Range("S1") Then
Rows("599:599").Select
Selection.Delete Shift:=xlUp
End If
End Sub
.
|