Thread: [Solved] Hide Row With Zero Values
View Single Post
 
Old 03-19-2020, 07:11 AM
Marcia's Avatar
Marcia Marcia is offline Windows 7 32bit Office 2013
Expert
 
Join Date: May 2018
Location: Philippines
Posts: 527
Marcia has a spectacular aura aboutMarcia has a spectacular aura aboutMarcia has a spectacular aura about
Default

Hi Jeffrey, I modified the Code in Post #2 as follows:
HTML Code:
rng.Formula = "=IF(E2<>"""",""Printed"",IF(B2<>"""",""Print"",""""))"
        For Each c In rng
            If c.Value = "Printed" Then ws.Rows(c.Row).EntireRow.Hidden = True
            If c.Value = "" Then ws.Rows(c.Row).EntireRow.Hidden = True
Next c
I would like the Code to hide rows if the value in the range is either "Printed" or blank.
Another please. The range is F2:F26 but the formula when run ends until F2626 not F26.
Thank you.

Last edited by Marcia; 03-19-2020 at 08:07 PM.
Reply With Quote