Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to make Combo Boxes not duplicate options
If you pick the Atlanta option(in the VBA code below) when you go back and
re-open the combo box it relists all the options atleast three times or more. Is there any way after you make a selection on a combo box to keep the option from duplicating and only show the list of options once? Private Sub ComboBox1_Change() ComboBox1.AddItem "" ComboBox1.AddItem "Atlanta" ComboBox1.AddItem "Chicago" ComboBox1.AddItem "Washington DC" Sheets("Questionaire").Range("N7") = ComboBox1.Value |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to make Combo Boxes not duplicate options
Why would you add the items to the combobox in the _change event?
If this is in a userform, maybe you could use userform_initialize to populate that combobox. Rusty wrote: If you pick the Atlanta option(in the VBA code below) when you go back and re-open the combo box it relists all the options atleast three times or more. Is there any way after you make a selection on a combo box to keep the option from duplicating and only show the list of options once? Private Sub ComboBox1_Change() ComboBox1.AddItem "" ComboBox1.AddItem "Atlanta" ComboBox1.AddItem "Chicago" ComboBox1.AddItem "Washington DC" Sheets("Questionaire").Range("N7") = ComboBox1.Value -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Getting Combo boxes to change options based on other Combo boxes. | New Users to Excel | |||
Make text cells and combo boxes required? | Excel Discussion (Misc queries) | |||
Selecting subsets using combo boxes or list boxes | Excel Discussion (Misc queries) | |||
Filtered list for Combo Box ListFillRange - Nested Combo Boxes | Excel Programming | |||
Options and Combo Boxes | Excel Programming |