Returns the first data point with a minimum value, and can be used in a loop to locate ALL data points in the collection with this minimum value. The search starts at the specified index.
Find first point with Min value from specified index.
Visual Basic (Declaration) | |
---|---|
Public Overloads Function FindMinValue( _ ByVal useValue As String, _ ByRef startFromIndex As Integer _ ) As DataPoint |
Visual Basic (Usage) | Copy Code |
---|---|
|
C# | |
---|---|
public DataPoint FindMinValue( string useValue, ref int startFromIndex ) |
Parameters
- useValue
-
The point value to be examined (e.g. X, Y, Y2, etc.).
Which point value to use (X, Y1, Y2,...). - startFromIndex
-
The location within the collection to start the search at (0-based). If a data point is found this parameter will be populated with the index of the returned data point, otherwise it will be set to negative one (-1).
Index of the point to start looking from. Returns index of found point or -1.
Return Value
A DataPoint object in the DataPointCollection with the minimum specified value. If no data point is found then null will be returned.
Found point or null.
The following sample returns ALL data points with the minimum second Y-value. We then change the color of all returned data points.
Visual Basic | Copy Code |
---|---|
Imports Dundas.Charting.WebControl |
C# | Copy Code |
---|---|
using Dundas.Charting.WebControl; |
This method starts the search at the specified index, and will return the first data point with the minimum value.
There may be more than one data point in the collection with a minimum value, and it is this minimum value that determines if a data point is returned. This definition can be used in a loop to locate ALL points in the collection that have a maximum value, and is accomplished by incrementing the startFromIndex parameter in the loop that is performing the search.
Note that a point will only be returned if its value is the minimum for all points in the collection.
Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family