Delete Row

B

Blue

Hi

I want to delete any row that has 0 in column O starting at row 4 and
continuing to the end of column O, at the moment column O is 3600 rows but
this will increase.

Thanks in advance

Blue
 
F

Frank Kabel

Hi
try the following macro
Sub delete_rows()
Dim RowNdx As Long
Dim LastRow As Long
Application.ScreenUpdating = False
LastRow = ActiveSheet.Cells(Rows.Count, "O").End(xlUp).row
For RowNdx = LastRow To 4 Step -1
with Cells(RowNdx, "O")
if .value = 0 then
Rows(RowNdx).Delete
End If
end with
Next RowNdx
Application.ScreenUpdating = True
End Sub
 
B

Blue

Wow that was quick.

Thanks Frank that worked great, Ron will have a look at your site.

Have another query but will start another post.

Thanks Blue
 
Top