Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to run when sheet activated
Place this code in the 'ThisWorkbook' section of the VBE:
David Miller ================================================== == Private Sub Workbook_SheetActivate(ByVal Sh As Object) If Sh.Name = "Trigger" Then Sheets("A").Visible = True Sheets("A").Visible = True Sheets("A").Visible = True End If End Sub |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to run when sheet activated
Try this:
David Miller ================================================== ================ Private Sub Workbook_SheetActivate(ByVal Sh As Object) If Sh.Name = "Trigger" Then If Sheets("A").vibible = True And Sheets("B").Visible = True And Sheets("C").Visible = True Then Sheets("A").Visible = True Sheets("B").Visible = True Sheets("C").Visible = True Else Sheets("A").Visible = True Sheets("B").Visible = True Sheets("C").Visible = True End If End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Password prompt when sheet is activated | Excel Programming | |||
userform open when sheet activated | Excel Programming | |||
Load VBA on Activated Sheet | Excel Programming | |||
Error sheet when macro's are not activated | Excel Programming | |||
VBA - Left Shift to be Activated when Sheet is selected. | Excel Programming |