Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
Is there a way to programmatically retract the dropdown list for a combobox on a form? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
See VBA help ShowDropButtonWhen Property fmShowDropButtonWhenNever 0 Do not show the drop-down button under anycircumstances. fmShowDropButtonWhenFocus 1 Show the drop-down button when the control has the focus. fmShowDropButtonWhenAlways 2 Always show the drop-down button. "joeeng" wrote: Is there a way to programmatically retract the dropdown list for a combobox on a form? |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
Thanks, Joel However, this is not quite what I am looking for. I would like to hide (retract) the dropdown list itself (not the button) when the user types something in the combobox that does not match anything in the dropdown list. I have worked out the procedure, but I cannot figure out how to get the dropdown list to hide itself. Dropdown method makes it appear, but what makes it retract? "Joel" wrote: See VBA help ShowDropButtonWhen Property fmShowDropButtonWhenNever 0 Do not show the drop-down button under anycircumstances. fmShowDropButtonWhenFocus 1 Show the drop-down button when the control has the focus. fmShowDropButtonWhenAlways 2 Always show the drop-down button. "joeeng" wrote: Is there a way to programmatically retract the dropdown list for a combobox on a form? |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
What about disable the combobox? You can check the properties window in the userform (select combobox) to see all the options. You can change them manual in the property window so you can see the effectr of each change before adding code to perform same operation. If the property window doesn't display the go to menu View to add the window. "joeeng" wrote: Thanks, Joel However, this is not quite what I am looking for. I would like to hide (retract) the dropdown list itself (not the button) when the user types something in the combobox that does not match anything in the dropdown list. I have worked out the procedure, but I cannot figure out how to get the dropdown list to hide itself. Dropdown method makes it appear, but what makes it retract? "Joel" wrote: See VBA help ShowDropButtonWhen Property fmShowDropButtonWhenNever 0 Do not show the drop-down button under anycircumstances. fmShowDropButtonWhenFocus 1 Show the drop-down button when the control has the focus. fmShowDropButtonWhenAlways 2 Always show the drop-down button. "joeeng" wrote: Is there a way to programmatically retract the dropdown list for a combobox on a form? |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
Joel, Based on your idea, a simple workaround worked. Combobox.Enabled=False Combobox.Enabled=True Combobox.SetFocus This hides the dropdown list and returns to the combobox exactly where the user left off typing the new entry. Thanks for the idea. "Joel" wrote: What about disable the combobox? You can check the properties window in the userform (select combobox) to see all the options. You can change them manual in the property window so you can see the effectr of each change before adding code to perform same operation. If the property window doesn't display the go to menu View to add the window. "joeeng" wrote: Thanks, Joel However, this is not quite what I am looking for. I would like to hide (retract) the dropdown list itself (not the button) when the user types something in the combobox that does not match anything in the dropdown list. I have worked out the procedure, but I cannot figure out how to get the dropdown list to hide itself. Dropdown method makes it appear, but what makes it retract? "Joel" wrote: See VBA help ShowDropButtonWhen Property fmShowDropButtonWhenNever 0 Do not show the drop-down button under anycircumstances. fmShowDropButtonWhenFocus 1 Show the drop-down button when the control has the focus. fmShowDropButtonWhenAlways 2 Always show the drop-down button. "joeeng" wrote: Is there a way to programmatically retract the dropdown list for a combobox on a form? |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
I finally remembered the right way to do it. set index number to -1. "joeeng" wrote: Joel, Based on your idea, a simple workaround worked. Combobox.Enabled=False Combobox.Enabled=True Combobox.SetFocus This hides the dropdown list and returns to the combobox exactly where the user left off typing the new entry. Thanks for the idea. "Joel" wrote: What about disable the combobox? You can check the properties window in the userform (select combobox) to see all the options. You can change them manual in the property window so you can see the effectr of each change before adding code to perform same operation. If the property window doesn't display the go to menu View to add the window. "joeeng" wrote: Thanks, Joel However, this is not quite what I am looking for. I would like to hide (retract) the dropdown list itself (not the button) when the user types something in the combobox that does not match anything in the dropdown list. I have worked out the procedure, but I cannot figure out how to get the dropdown list to hide itself. Dropdown method makes it appear, but what makes it retract? "Joel" wrote: See VBA help ShowDropButtonWhen Property fmShowDropButtonWhenNever 0 Do not show the drop-down button under anycircumstances. fmShowDropButtonWhenFocus 1 Show the drop-down button when the control has the focus. fmShowDropButtonWhenAlways 2 Always show the drop-down button. "joeeng" wrote: Is there a way to programmatically retract the dropdown list for a combobox on a form? |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
retract dropdown for combobox
I tried setting listindex to -1 and this is what I found. Setting the listindex to -1 merely removes the selection focus from the dropdown. It does not hide the dropdown list. "Joel" wrote: I finally remembered the right way to do it. set index number to -1. "joeeng" wrote: Joel, Based on your idea, a simple workaround worked. Combobox.Enabled=False Combobox.Enabled=True Combobox.SetFocus This hides the dropdown list and returns to the combobox exactly where the user left off typing the new entry. Thanks for the idea. "Joel" wrote: What about disable the combobox? You can check the properties window in the userform (select combobox) to see all the options. You can change them manual in the property window so you can see the effectr of each change before adding code to perform same operation. If the property window doesn't display the go to menu View to add the window. "joeeng" wrote: Thanks, Joel However, this is not quite what I am looking for. I would like to hide (retract) the dropdown list itself (not the button) when the user types something in the combobox that does not match anything in the dropdown list. I have worked out the procedure, but I cannot figure out how to get the dropdown list to hide itself. Dropdown method makes it appear, but what makes it retract? "Joel" wrote: See VBA help ShowDropButtonWhen Property fmShowDropButtonWhenNever 0 Do not show the drop-down button under anycircumstances. fmShowDropButtonWhenFocus 1 Show the drop-down button when the control has the focus. fmShowDropButtonWhenAlways 2 Always show the drop-down button. "joeeng" wrote: Is there a way to programmatically retract the dropdown list for a combobox on a form? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
opposite of dropdown in combobox | Excel Programming | |||
Combobox dropdown list??????????? | Excel Discussion (Misc queries) | |||
ComboBox dropdown list? | Excel Discussion (Misc queries) | |||
Combobox.DropDown not working | Excel Programming | |||
combobox dropdown | Excel Programming |