Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I need to hide rows based on the value in Column AV, and can't use AutoFilter
because AV is not contiguous with other columns where I am already using Autofilter for other purposes. I can't move the column to make it contiguous either, as that would screw up other things. So I'm looking for code that will say, for each row in the active worksheet, if AV = "C", hide the row. (Yes, I'd probably want to limit it to only rows that contain some data, rather than churning through all 65535 rows!) I'm lost, though, as to how to refer to the relevant cell in column AV. Who can help? |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
sub test()
for each c in range("av1:av1000") ' change range to fit if c="C" then c.entirerow.hidden=true next end sub "LarryP" skrev: I need to hide rows based on the value in Column AV, and can't use AutoFilter because AV is not contiguous with other columns where I am already using Autofilter for other purposes. I can't move the column to make it contiguous either, as that would screw up other things. So I'm looking for code that will say, for each row in the active worksheet, if AV = "C", hide the row. (Yes, I'd probably want to limit it to only rows that contain some data, rather than churning through all 65535 rows!) I'm lost, though, as to how to refer to the relevant cell in column AV. Who can help? |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Knew it had to be simpler than I was imagining! Thanks.
"excelent" wrote: sub test() for each c in range("av1:av1000") ' change range to fit if c="C" then c.entirerow.hidden=true next end sub "LarryP" skrev: I need to hide rows based on the value in Column AV, and can't use AutoFilter because AV is not contiguous with other columns where I am already using Autofilter for other purposes. I can't move the column to make it contiguous either, as that would screw up other things. So I'm looking for code that will say, for each row in the active worksheet, if AV = "C", hide the row. (Yes, I'd probably want to limit it to only rows that contain some data, rather than churning through all 65535 rows!) I'm lost, though, as to how to refer to the relevant cell in column AV. Who can help? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Hiding rows based on a cell? | Excel Worksheet Functions | |||
hiding or showing rows based on a cell value | Excel Discussion (Misc queries) | |||
Hiding rows based value of cell within row | Excel Discussion (Misc queries) | |||
If / Else Code (hiding rows based on cell value) | Excel Programming | |||
Hiding rows based on cell content | Excel Programming |