View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Jef Gorbach[_2_] Jef Gorbach[_2_] is offline
external usenet poster
 
Posts: 65
Default Hide Rows if all values are zero

Dont have a copy of Excel handy to test, but sounds like you want
something along the lines of:

Sub untested()
Dim myrange As Range
For row = 2 to Range("A65536").End(Xlup).Row
myrange = Range(Cells(row,"A"),Cells(row,"d"))
If Application.WorksheetFunction.Sum(myrange) = 0 Then
myrange.EntireRow.Delete
Next
End Sub