Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

LinqDataSource::ContextDisposing Event

 

Occurs before disposing the context type object.

Namespace:   System.Web.UI.WebControls
Assembly:  System.Web.Extensions (in System.Web.Extensions.dll)

public:
event EventHandler<LinqDataSourceDisposeEventArgs^>^ ContextDisposing {
	void add(EventHandler<LinqDataSourceDisposeEventArgs^>^ value);
	void remove(EventHandler<LinqDataSourceDisposeEventArgs^>^ value);
}

You handle the ContextDisposing event to dispose the object manually, or to perform clean-up that is specific to the object before the object is destroyed.

.NET Framework
Available since 3.5
Return to top
Show:
© 2017 Microsoft