Combo Box

Hazeyt

New Member
Joined
Jan 23, 2023
Messages
29
Office Version
  1. 365
I am using combo boxes where one department might have 50 sub depts and another might have only 8.

How do you get the combo box to default to the top record? as some users may not realise you have to scroll back up to the top?

Many thanks
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
Hi,
Have you tested: Combobox1.SelectedIndex = 0
 
Upvote 0
Please can you give me the code behind this?

The combo box is just a form control from developer and not part of user form if makes difference?

Thanks
 
Upvote 0
Whenever you are working with objects directly in your spreadsheet, you do have the choice between Form Controls and ActiveX Controls ...

Features are not identical ... Which type have you picked ...?
 
Upvote 0
Whenever you are working with objects directly in your spreadsheet, you do have the choice between Form Controls and ActiveX Controls ...

Features are not identical ... Which type have you picked ...?
Form Controls thanks
 
Upvote 0
You can test following
VBA Code:
Sub ResetFormDropDown()
Dim dd As DropDown
Set dd = ActiveSheet.Shapes("Drop Down 1").OLEFormat.Object
dd.ListIndex = 1
End Sub
 
Upvote 0
Solution

Forum statistics

Threads
1,214,926
Messages
6,122,305
Members
449,079
Latest member
juggernaut24

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top