UnTrapping of Mouse Events
-
Is there an easy way of passing mouse events from a control to the form below in, e.g i have a label on the form and want any mouse events that happen on the label to be passed to the form underneath it. I cant just disable the label (e.g. label.Enabled = false) as i still want the label to be able to respond to the events before the form. My only idea is to send another message to the form when the label recives it, but this seems a little long winded. Barry :confused:
-
Is there an easy way of passing mouse events from a control to the form below in, e.g i have a label on the form and want any mouse events that happen on the label to be passed to the form underneath it. I cant just disable the label (e.g. label.Enabled = false) as i still want the label to be able to respond to the events before the form. My only idea is to send another message to the form when the label recives it, but this seems a little long winded. Barry :confused:
wheelerbarry wrote:
My only idea is to send another message to the form when the label recives it, but this seems a little long winded.
And it's the only way to do it. Mouse clicks will not go to all (or selected) windows beneath the spot where the mouse was. You actually have to create a new mouse message and manually send it to the windows you want. For this, you'll have to have the window's handle (hWnd). RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome