Need auto hide rows macro to also hide Forms Check Boxes

RobbieNZ

New Member
Joined
Aug 17, 2010
Messages
21
Hi I have a macro that sits within different sheets in my workbook and hides rows based on the result in a cell.
I thought this was great until I added in Forms Check Boxes yesterday and found that rather than hide, these boxes just move down the page.

Is there any way to get the check boxes on the rows that are being hidden to also hide. There will be checkboxes that do not get hidden in the same sheet.

This is what I am using at the moment.
I need the Forms check boxes in the corresponding rows to also hide?
Is this possible and duplicatable in different sheets

** I wrote a similar post at the end of an old thread yesterday but was not sure if that was the correct place to put it so have posted a new thread here, hope this is ok.

Code:
Private Sub Worksheet_Calculate()
 
Dim myresult4 As String
Application.EnableEvents = False
Rows("1:" & Worksheets("PUMP CONTROL").UsedRange.Rows.Count).EntireRow.Hidden = False
 
 
myresult4 = Worksheets("PUMP CONTROL").Cells(22, 1).Value 'FGC options
Select Case myresult4
 
Case "", "None", "0", "APP"
Rows("22:26").EntireRow.Hidden = True
Rows("49:52").EntireRow.Hidden = True
 
End Select
 
 
Application.EnableEvents = True
End Sub
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
Instead of a form control try using activex control and set its properties to move and size with cells. This should do what u want....
 
Upvote 0
Sigh, that is what I was afraid of.

I guess I better figure out how to write an event handler.

Any ideas - I just want the check box to generate = 'True' to a different sheet if clicked. Each check box would independantly generate = True when clicked and poulate that response in separate cells in the different sheet.
 
Upvote 0

Forum statistics

Threads
1,214,614
Messages
6,120,525
Members
448,969
Latest member
mirek8991

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top