Welcome Guest!
 VB Helper Q & A
 Previous Message All Messages Next Message 
RE: Indexing controls on windows forms  Rod Stephens
 Apr 17, 2010 05:57 PDT 

You can also assign them the same event handler in the code editor by
adding more Handles clauses at the end of the event handler's
declaration. For example:

    Private Sub Button1_Click(...) _
      Handles Button1.Click, Button2.Click

    End Sub

And you can use AddHandler and RemoveHandler if you want to add and
remove event handlers at run time.


Rod Stephens, Visual Basic MVP

Visual Basic 2010 Programmer's Reference
 Previous Message All Messages Next Message 
  Check It Out!

  Topica Channels
 Best of Topica
 Art & Design
 Books, Movies & TV
 Food & Drink
 Health & Fitness
 News & Information
 Personal Finance
 Personal Technology
 Small Business
 Travel & Leisure
 Women & Family

  Start Your Own List!
Email lists are great for debating issues or publishing your views.
Start a List Today!

© 2001 Topica Inc. TFMB
Concerned about privacy? Topica is TrustE certified.
See our Privacy Policy.