![]() |
Hide all values in a row if value is 0
I am putting together a forecast sheet for part requirements and with so many
parts to deal with I would like to set it up so that anytime the required amount is 0, then the entire row is hidden. Currently I have a simple formula to just show a blank cell. It is time consuming to review 300 P/N when I may only need 14 P/N that week. How can I go about hidding the entire row in a formula? Thank you, Erik |
Hide all values in a row if value is 0
You can't. Not with a formula. A formula will only return a value. You
will have to use VBA to hide the rows. I assume that the required amount is in some column from this row to that row. Is that correct? If so, then you can use something like this: Say that Column F holds the amounts. Sub HideRows() Dim TheRng As Range Dim i As Range Set TheRng = Range("F2", Range("F" & Rows.Count).End(xlUp)) For Each i In TheRng If i.Value = 0 Then i.EntireRow.Hidden = True Next i End Sub HTH Otto "Erik T" wrote in message ... I am putting together a forecast sheet for part requirements and with so many parts to deal with I would like to set it up so that anytime the required amount is 0, then the entire row is hidden. Currently I have a simple formula to just show a blank cell. It is time consuming to review 300 P/N when I may only need 14 P/N that week. How can I go about hidding the entire row in a formula? Thank you, Erik |
All times are GMT +1. The time now is 11:44 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com