DataManipulator::Sort Method (IComparer<DataPoint>, String)
Performs a custom sort on one or more series.
Assembly: System.Web.DataVisualization (in System.Web.DataVisualization.dll)
Parameters
- comparer
- Type: System.Collections.Generic::IComparer<DataPoint>
An object that implements the IComparer interface and provides the custom sorting logic.
- seriesName
- Type: System::String
A comma-separated list of names of the Series to be sorted.
This method performs a custom sort on the data points in one or more series; the sort logic is defined by the comparer parameter. Override and implement the Compare method of the IComparer interface, perform the comparison(s) and then return true or false. The sort order is determined by the return value.
Note that if multiple series are sorted, the series must be aligned, otherwise an exception will be thrown.
The two object parameters of the Compare method must always be of type DataPoint.
Important |
|---|
All data points, regardless of the series they belong to, are sorted based on the first series; if the position of a data point in the first series changes, all corresponding points in the other series change as well. |
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Important