ActiveX drop down keeps expanding

STEEL010

Board Regular
Joined
Dec 29, 2017
Messages
76
Dear all,

I want to have an solution for next thing.

I have activeX control drop down box and when I used it and it give results there is no problem. but when a select or edit an other cell and enter then the drop down menu expands???

See below my code, hopefully somebody can help.

Private Sub ComboBox1_Change()
ComboBox1.DropDown
If Range("B5").Value <> "" Then
Range("B6").Value = Evaluate("=VLookup(B5,SEARCH, 7, 0)")
Else
On Error Resume Next
Range("B6").ClearContents
End If
End Sub


Greetings,

Steel010
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Use a forms control dropdown instead. You're better off not using ActiveX controls on worksheets at all. They're incredibly unstable have a look here https://www.google.co.uk/webhp?sour...espv=2&ie=UTF-8#q=resizing worksheet controls and by using them, you're asking for trouble.

Forms controls are much more reliable - they're in the same dropdown as the ActiveX ones, but are designed for use on worksheets - so you don't run into any stability issues, you can do most of the same things with them too and you can use them without using code.
 
Upvote 0

Forum statistics

Threads
1,224,822
Messages
6,181,165
Members
453,021
Latest member
Justyna P

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