R
RyanH
I have a custom menu tab that contains a submenu item which contains a
combobox. I would like to set the zoom property of several worksheets to the
value of the combobox when it is changed.
1.) How can I get the value of the combobox? I want to call this Sub when
the combox is changed.
Public Sub ChangeDeptViews()
SubName = "ChangeDeptViews"
' make sure Global Schedule is the active sheet
If Not IsGlobalAvailable() Then
Exit Sub
End If
Application.ScreenUpdating = False
' store current sheet
Set wksCurrentSheet = ActiveSheet
Sheets(Array("Engineering", "Graph Prod", "Metal Fab", "Alum Ext", _
"Custom Fab", "Electrical", "Ch Ltrs", "Foam Fab", _
"Metal Paint", "Thermo", "Tri Graphics", "Deco Faces", _
"Tri-Face", "LED", "Crating", "Service",
"Delivery")).Select
Sheets("Engineering").Activate
DOESN'T WORK>>> ActiveWindow.Zoom = CommandBars(1).Controls("Depts.
View").Value
' restore sheet that was active
wksCurrentSheet.Activate
Application.ScreenUpdating = False
End Sub
combobox. I would like to set the zoom property of several worksheets to the
value of the combobox when it is changed.
1.) How can I get the value of the combobox? I want to call this Sub when
the combox is changed.
Public Sub ChangeDeptViews()
SubName = "ChangeDeptViews"
' make sure Global Schedule is the active sheet
If Not IsGlobalAvailable() Then
Exit Sub
End If
Application.ScreenUpdating = False
' store current sheet
Set wksCurrentSheet = ActiveSheet
Sheets(Array("Engineering", "Graph Prod", "Metal Fab", "Alum Ext", _
"Custom Fab", "Electrical", "Ch Ltrs", "Foam Fab", _
"Metal Paint", "Thermo", "Tri Graphics", "Deco Faces", _
"Tri-Face", "LED", "Crating", "Service",
"Delivery")).Select
Sheets("Engineering").Activate
DOESN'T WORK>>> ActiveWindow.Zoom = CommandBars(1).Controls("Depts.
View").Value
' restore sheet that was active
wksCurrentSheet.Activate
Application.ScreenUpdating = False
End Sub