C Sharp form constant updating?

action, c#, forms, methods

Solution

Once you've created the method once you should be able to use it for any other event that has a similar signature.

From the Designer, don't double-click the method but instead drop down the list for any existing event handler that can be assigned to your chosen event.

Like @lcfseth notes, you can identify which particular control sent the message via the `object sender` argument.

Problem

Through Visual Studio you can easily create a method for an event (button click, etc). Is there a way to create a method for multiple events, like a method that would run any time one of three buttons were clicked, or one of many textboxes were typed in?

Original source