I am trying to create a user form that will unhide a specific worksheet based on the value of the combo box on the user form. There are 3 different worksheets that are " very hidden" in the workbook. The combo box is populated with 3 choices, one for each hidden sheet. I am using select case to make the correct sheet visible (Eventually there will be many more than 3 sheets/options. Sample code follows (located in the user form code window):
Private Sub NextButton_Click()
Select Case ComboBox
Case ComboBox.ListIndex = 0
Sheets(1).Visible = True
Case ComboBox.ListIndex = 1
Sheets(2).Visible = True
Case ComboBox.ListIndex = 2
Sheets(3).Visible = True
End Select
Unload UserForm
End Sub
I click the next button, the userform unloads, but the sheets does not become visible. VBA brings up no errors either. Please let me know if I need to provide any more information.
Nik