Component.Disposed Event


在通过调用 Dispose() 方法释放组件时发生。Occurs when the component is disposed by a call to the Dispose() method.

 virtual event EventHandler ^ Disposed;
public event EventHandler Disposed;
member this.Disposed : EventHandler 
Public Custom Event Disposed As EventHandler 




当创建 Disposed 委托时,请标识将处理事件的方法。When you create a Disposed delegate, you identify the method that handles the event. 若要将事件与事件处理程序关联,请将该委托的一个实例添加到事件中。To associate the event with your event handler, add an instance of the delegate to the event. 除非移除了该委托,否则每当发生该事件时就会调用事件处理程序。The event handler is called whenever the event occurs, unless you remove the delegate. 有关事件处理程序委托的详细信息,请参阅处理和引发事件For more information about the event handler delegates, see Handling and Raising Events.

Applies to

See also