Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Why is this giving me runtime error 438?
Sub ComboBox6_Change() If Sheets("Main Menu").ComboBox6.Value = "Main Menu" Then Call DisplayMenu If Sheets("Main Menu").ComboBox6.Value = "Goals" Then Call DisplayGoals If Sheets("Main Menu").ComboBox6.Value = "Development Plan" Then Call DisplayDevPlan If Sheets("Main Menu").ComboBox6.Value = "Mid-Year" Then Call DisplayMidYear If Sheets("Main Menu").ComboBox6.Value = "Self-Evaluation" Then Call DisplaySelfEval If Sheets("Main Menu").ComboBox6.Value = "Functional Manager" Then Call DisplayFunctionalMgr If Sheets("Main Menu").ComboBox6.Value = "Manager" Then Call DisplayManager End Sub Anyone? |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
m,
Is the ComboBox from the Control Tool Box and not from the Forms toolbar ? Does the sheet have the exact name "Main Menu" ? Is the code located in the sheet module ? Is the combobox actually named "ComboBox6" ? Does it work if you replace...Sheets("Main Menu") with...Me ? Jim Cone San Francisco, USA wrote in message oups.com Why is this giving me runtime error 438? Sub ComboBox6_Change() If Sheets("Main Menu").ComboBox6.Value = "Main Menu" Then Call DisplayMenu If Sheets("Main Menu").ComboBox6.Value = "Goals" Then Call DisplayGoals If Sheets("Main Menu").ComboBox6.Value = "Development Plan" Then Call DisplayDevPlan If Sheets("Main Menu").ComboBox6.Value = "Mid-Year" Then Call DisplayMidYear If Sheets("Main Menu").ComboBox6.Value = "Self-Evaluation" Then Call DisplaySelfEval If Sheets("Main Menu").ComboBox6.Value = "Functional Manager" Then Call DisplayFunctionalMgr If Sheets("Main Menu").ComboBox6.Value = "Manager" Then Call DisplayManager End Sub Anyone? |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Jim,
From the control toolbox, yes. I edited the code a bit (see below) and now nothing at all is happening when I select something from the dropdown menu.... what do you think? Sub ComboBox6() If Sheets("Competencies").ComboBox6.Value = "Main Menu" Then Call DisplayMenu If Sheets("Competencies").ComboBox6.Value = "Goals" Then Call DisplayGoals If Sheets("Competencies").ComboBox6.Value = "Development Plan" Then Call DisplayDevPlan If Sheets("Competencies").ComboBox6.Value = "Mid-Year" Then Call DisplayMidYear If Sheets("Competencies").ComboBox6.Value = "Self-Evaluation" Then Call DisplaySelfEval If Sheets("Competencies").ComboBox6.Value = "Functional Manager" Then Call DisplayFunctionalMgr If Sheets("Competencies").ComboBox6.Value = "Manager" Then Call DisplayManager End Sub |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
m,
I think that the sheet name should be the name of the sheet that the combobox is on. I also think that the code belongs in the code module behind the sheet (right-click the sheet tab and select "view code"). Jim Cone wrote in message oups.com Jim, From the control toolbox, yes. I edited the code a bit (see below) and now nothing at all is happening when I select something from the dropdown menu.... what do you think? Sub ComboBox6() If Sheets("Competencies").ComboBox6.Value = "Main Menu" Then Call DisplayMenu If Sheets("Competencies").ComboBox6.Value = "Goals" Then Call DisplayGoals If Sheets("Competencies").ComboBox6.Value = "Development Plan" Then Call DisplayDevPlan If Sheets("Competencies").ComboBox6.Value = "Mid-Year" Then Call DisplayMidYear If Sheets("Competencies").ComboBox6.Value = "Self-Evaluation" Then Call DisplaySelfEval If Sheets("Competencies").ComboBox6.Value = "Functional Manager" Then Call DisplayFunctionalMgr If Sheets("Competencies").ComboBox6.Value = "Manager" Then Call DisplayManager End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Counting instances of found text (Excel error? Or user error?) | Excel Worksheet Functions | |||
I have Error 1919 Error Configuring ODBC dataSource Database | Excel Discussion (Misc queries) | |||
run-time error '1004': Application-defined or object-deifined error | Excel Programming | |||
Automation Error, Unknown Error. Error value - 440 | Excel Programming |