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.
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