Hello Anne,
Originally Posted by
Dreamboat
Sorry. But if the cell say 0.00, then this does not hold. If the VALUE in A1 is zero, but NOT when it is blank.
As text? Coerce column A's values first then.
Try the following:
Sub HideRowsWithZeros3()
Dim ws As Worksheet
Application.ScreenUpdating = False
On Error Resume Next
For Each ws In ThisWorkbook.Worksheets
With ws
.AutoFilterMode = False
With .Range("a1")
.EntireRow.Hidden = (CBool(Len(.Value)) And .Value = 0)
End With
Range(.Cells(1, 1), .Cells(65336, 1).End(xlUp)) _
.AutoFilter Field:=1, Criteria1:="<>0", _
visibleDropDown:=False
End With
Next
Application.ScreenUpdating = True
End Sub
Sub HideRowsWithZeros3()
Dim ws As Worksheet
Application.ScreenUpdating = False
On Error Resume Next
For Each ws In ThisWorkbook.Worksheets
With ws
.AutoFilterMode = False
With .Range("a1")
.EntireRow.Hidden = (CBool(Len(.Value)) And .Value = 0)
End With
Range(.Cells(1, 1), .Cells(65336, 1).End(xlUp)) _
.AutoFilter Field:=1, Criteria1:="<>0", _
visibleDropDown:=False
End With
Next
Application.ScreenUpdating = True
End Sub
Edit: VBA tags are getting readable on Netscape. The one thing is that it tabs as it thinks I should tab, not as I actually tab.