ComboBox droplist open/clsoe

G

Guest

Is there a way to open and close the droplist on a combobox
If there is no direct way, How can I send a Click Event to this Control

Thanks
 
G

Guest

Ok, I found out the way to send a Message to the Control. I thought for sure a "Click" event would do what I want but it does not
I want to be able to drop and close the list view onthe control.
Does anyone know what messages I would need to send

The code I am using is this
Message msg = Message.Create( mHwnd1, WM_LBUTTONDOWN, (System.IntPtr) 0, (System.IntPtr) 0)
MessageWindow.SendMessage(ref msg)

But it seems that WM_LBUTTONDOWN just open the list view but does not close it. Strange

Thank
 
G

Guest

I got a little closer but it doe snot work
Where can I find the actual value of CB_SHOWDROPDOWN so I can define it in my application
 
G

Guest

Ahghg. Ok I got CB_SHOWDROPDOWN working, problem is, now I need to know if the dopr list is up or down
I could use CB_GETDROPPEDSTATE but SendMessage returns a void, so how would I get the actual state of the list

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top