This documentation is archived and is not being maintained.

ListControlDesigner.OnDataSourceChanged Method

Raises the DataSourceChanged event.

[Visual Basic]
Public Overridable Sub OnDataSourceChanged()
[C#]
public virtual void OnDataSourceChanged();
[C++]
public: virtual void OnDataSourceChanged();
[JScript]
public function OnDataSourceChanged();

Remarks

Handles changes made to the data source.

Example

[Visual Basic] The following code example overrides the OnDataSourceChanged method in a class that inherits from the ListControlDesigner class. When the data source associated with the designer class changes, OnDataSourceChanged is called and this code sets a Boolean variable named changedDataSource to true.

[Visual Basic] This code example is part of a larger example provided for the ListControlDesigner class.

[Visual Basic] 
' If the data source changes, set
' a Boolean variable to true.
Overrides Public Sub OnDataSourceChanged()
    changedDataSource = True
End Sub

[C#, C++, JScript] No example is available for C#, C++, or JScript. To view a Visual Basic example, click the Language Filter button Language Filter in the upper-left corner of the page.

Requirements

Platforms: Windows 2000, Windows XP Professional, Windows Server 2003 family

.NET Framework Security: 

See Also

ListControlDesigner Class | ListControlDesigner Members | System.Web.UI.Design.WebControls Namespace

Show: