Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
checkbox to hide/show row
hi,
if anyone can help it'd be appreciated. Here is what I'd like to accomplish: on sheet3 I want to insert a Category with checkboxes next to each item On sheet one I want to hide/show categories that have been checked...and hide the rows if I uncheck them. thank u for your input |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
checkbox to hide/show row
Hi
The code below would be one way of doing it. Run this code in the worksheet with the checkboxes, it will control the hiding of rows 1-5 on sheet1. Option Explicit Dim WkSh As Worksheet Private Sub CheckBox1_Click() Set WkSh = ThisWorkbook.Sheets("Sheet1") If CheckBox1.Value = False Then WkSh.Rows("1:5").EntireRow.Hidden = True Else If WkSh.Rows("1:5").Hidden = True Then WkSh.Rows("1:5").EntireRow.Hidden = False End If End If End Sub Hope this helps Steve |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
use checkbox to hide rows | Excel Discussion (Misc queries) | |||
Hide & Unhide with a Checkbox | Excel Programming | |||
hide rows from checkbox | Excel Programming | |||
hide or unhide pivotfield using a checkbox | Excel Programming | |||
Checkbox to hide or show rows | Excel Programming |