Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
combobox close on mouse move
Is it possible for a combobox dropdown list to close (as if a selection was made), if the mouse moves out of the list. I notice the pointer chances from a cross to the normal pointer as the mouse moves off the list. I would ideally like to mimic a mouse clixk on the top item if the mouse moves off the list. Hope this is clear Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
combobox close on mouse move
You may get a better answer, but I don't think you can use the _MouseMove to get what you want. You can experiment with the events of a combobox by creating one on a worksheet and then creating the event subs for the events you want to learn about. At the top of the worksheet code put: Public lEvent as Long Then add to to the event sub some code like: Private Sub ComboBox1_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) lEvent = lEvent + 1 Debug.Print "mouse moved " & CStr(lEvent) End Sub Then, postion the VB IDE Immediate window where you can see it and still be able to interact with the combo box on the worksheet and watch which events your actions trigger. In this case, the _MouseMove fires repeatedly as the mouse moves around inside the combo box after the choices have been displayed, but stops firing when the mouse moves out of the combobox border. You may be able to do what you want with the _LostFocus event which fires after the combo box has been selected and then the user clicks off it onto a worksheet cell or some other control. Hope this helps... -- jamescox ------------------------------------------------------------------------ jamescox's Profile: http://www.thecodecage.com/forumz/member.php?userid=449 View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=112648 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Mouse Move | Excel Programming | |||
mouse focusing in close button in preview window | Excel Programming | |||
can't move UserForm with the mouse | Excel Programming | |||
Is clicking on the tab with my mouse the only way to move from on. | Excel Worksheet Functions | |||
Excel ComboBox mouse scroll | Excel Programming |