
Signature
Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm
> hi sorry for being a pain...
>
[quoted text clipped - 8 lines]
>
> thank you.
this is what i made out of the webpage
Sub deleterows2crtr()
ElseIf .Cells(Lrow, "E").Value = "2" And _
.Cells(Lrow, "G").Value <> 0 Then .Rows(Lrow).Delete
End Sub
it dosent seem to work though. Invalid criteria or something. Can you help
out?
S.
> Hi Steven
>
[quoted text clipped - 13 lines]
> >
> > thank you.
Ron de Bruin - 15 Feb 2007 15:44 GMT
Hi Steven
Try this
Sub Example2()
Dim Lrow As Long
Dim CalcMode As Long
Dim ViewMode As Long
Dim StartRow As Long
Dim EndRow As Long
With Application
CalcMode = .Calculation
.Calculation = xlCalculationManual
.ScreenUpdating = False
End With
ViewMode = ActiveWindow.View
ActiveWindow.View = xlNormalView
With ActiveSheet
.DisplayPageBreaks = False
StartRow = 1
EndRow = 5000
For Lrow = EndRow To StartRow Step -1
If .Cells(Lrow, "E").Value = 2 And _
.Cells(Lrow, "G").Value <> 0 Then .Rows(Lrow).Delete
Next
End With
ActiveWindow.View = ViewMode
With Application
.ScreenUpdating = True
.Calculation = CalcMode
End With
End Sub

Signature
Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm
> this is what i made out of the webpage
>
[quoted text clipped - 25 lines]
>> >
>> > thank you.
niewbe me... never mind I figured t out!
thank you!
> Hi Steven
>
[quoted text clipped - 13 lines]
> >
> > thank you.