Is there a way to synchronize two handlers for a single event ?
Also, is there a way to combine two different events that have the same handle ? Thanks
Printable View
Is there a way to synchronize two handlers for a single event ?
Also, is there a way to combine two different events that have the same handle ? Thanks
What do you mean?Quote:
Is there a way to synchronize two handlers for a single event ?
You can add items to handles statement at the end of the method that handles the event, if set at designtime. Or at runtime you can use AddHandler to specify which method handles an event.Quote:
Also, is there a way to combine two different events that have the same handle ?
VB Code:
Public Sub ClickHandler(sender as object, e as eventargs) Handles btnOk.Click, btnApply.Click AddHandler btnApply.Click,AddressOf ClickHandler
Can you tell me which events do i use to accomplish this :
The user clicks on a circle and drags it so that the circle becomes bigger. Now, I want to display the circle as it grows while the user drags it. Thanks for your time.
You are talking about a circle drawn through GDI, right? Then I don't believe it has events, or if it does I don't which ones, sorry.
May I suggest Control.MouseMove with a check to see if the button is depressed?
See there is no control associated with this. I draw a circle using createGraphics method. Thats why this is stumping me. I could have used the drag and drop if it were a control. I can use mousedown to get the coordinates when the user starts dragging and mouse up coords to find the distance dragged and then expand the circle. But I want the circle growing as the dragging is happening, the drag should be visible.
Would Form.MouseMove not work?