Avoiding a second click on a toolstrip button

R

Robert Jones

I have a toolstrip button on a windows form. If my form does not have focus,
when the user clicks on the toolstrip button nothing happens, and they have
to click a second time for the button to operate.

A System.Windows.Forms.Button also on the form does respond immediately -
even if the form does not have focus.

Is it possible to make the System.Windows.Forms.ToolStripButton respond
immediately also?
 
D

Daniel

Cant you do some kind of handling on the onfocus? So catch it gaining focus
and say, ok gained focus, was it from a mouse click, if so what button am i
on, do mouse click for that button? Something like that?
 
R

Robert Jones

Thanks for the suggestion - I've been trying to see what other events I can
respond to on the form rather than the object.

I added a list box and wrote a line for numerous events from the form when I
click on the toolstripbutton, the only event I am getting is the form
activate, and I can't seem to identify from that even what object was
clicked on - looking at the sender and EventArgs objects.

Does anyone have any other ideas?
 

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