To control the number of items displayed in a comboBox you can use the
MaxDropDownItems[
^] property. But it won't behave the way you expect it to unless you also adjust the
IntegralHeight[
^] property. E.g.
ComboBox3.IntegralHeight = False
ComboBox3.MaxDropDownItems = 10
The second part of your requirement is a little strange but can be achieved by simply resetting
IntegralHeight = True
. You have to be careful where to place this - if you use the
Click
event for example the Dropdown will briefly show then close again (don't blink or you'll miss it!). This is probably the best idea
Private Sub ComboBox3_DropDownClosed(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox3.DropDownClosed
ComboBox3.IntegralHeight = True
End Sub