共用方式為


AddHandler 

AddHandler associates an event with an event handler at run time, or declares what code to execute when adding an event handler.

Remarks

The AddHandler keyword is used in these contexts:

  • Event Statement
    The AddHandler keyword declares a custom AddHandler accessor.

See Also

Tasks

How to: Declare Events That Avoid Blocking
How to: Declare Events That Conserve Memory Use