I could not figure out a way to remove the rectangular box around the last
selected value in the pulldown menu without
Combo1.Clear
and then rebuilding the menu each time a combobox value is selected.
As for the highlight around the item displayed in the ComboBox before the
menu is pulled down you just have to set the focus to another control. You
can create a command button or another ComboBox and hide it behind your
existing control. Whenever the Combo1 receives a Change or Click event
just run this line of code:
Combo2.SetFocus
or
Command1.SetFocus
and the hidden ComboBox receives the focus and the highlighting disappears
from Combo1.
Hope this helps.
Tom
"Arlie Rahn" <ar*******@nospam.cox.net> wrote in message
news:YMmLc.2554$ml.76@lakeread05...
I am using a combo box with style =2 Dropdown List.
If you want to mimic this, just create a project with a combo box, put in
4-5 values into it on load and select the first one after running the
project. You will see a small rectangular box around the value selected. I
would like to find a way to remove that.
"Kiteman - Canada" <-d*************@shaw.ca> wrote in message
news:qSEKc.57410$ek5.31890@pd7tw2no... Are you using a ComboBox with Style=2 Dropdown List
or are you using a ListBox with Style=1 Standard?
I have used the following in a ListBox (in the _Click procedure) to get
rid of the standard blue box highlight AND the focus rectangle.
List1.Enabled = False
List1.ListIndex = -1
List1.Enabled = True
Maybe the above, or some combination of the above, would work with the
ComboBox?
Tom
"Arlie Rahn" <ar*******@nospam.cox.net> wrote in message
news:AFYJc.8046$%p4.2086@okepread04... Does anyone know of a way (using win32s perhaps) to eliminate that
focus rectangle over the selected option you see in a normal VB combo box?