Hello,
In my case I have panels,but to make it clear I will use buttons in my example.
I have 5(or more) buttons and I set an event,for example - OnMouseHover, to all of the five buttons.How do I get ,which one has the mouse hovered if all the events link to one method
To capture the button where the mouse is hovered,I tried using "this",but it links to the form itself.
private void buttonX_MouseHover(object sender, EventArgs e)
{
this.Text = "Test";
}
I expected the text on the specified button where the mouse is hovered to change its text to "Test",but it happened on the form.Text only.
In my real program,I have 60 panels and I again use one method for all OnMouseHover events on any of them.How do I get the panel(or button in the example above) where the mouse is hovered?