DataGrid.OnItemsSourceChanged Method (IEnumerable, IEnumerable)

.NET Framework (current version)
 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Invoked when the ItemsSource property changes.

Namespace:   System.Windows.Controls
Assembly:  PresentationFramework (in PresentationFramework.dll)

protected override void OnItemsSourceChanged(
	IEnumerable oldValue,
	IEnumerable newValue
)

Parameters

oldValue
Type: System.Collections.IEnumerable

The old source.

newValue
Type: System.Collections.IEnumerable

The new source.

If the AutoGenerateColumns property is true, columns are regenerated when the ItemsSource property changes. If possible, the cell or row selection will be maintained.

.NET Framework
Available since 4.0
Return to top
Show: