NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

ArrayList.Sort (Int32, Int32, IComparer)

Sorts the elements in a section of ArrayList using the specified comparer.

[Visual Basic]
Overloads Overridable Public Sub Sort( _
   ByVal index As Integer, _
   ByVal count As Integer, _
   ByVal comparer As IComparer _
)
[C#]
public virtual void Sort(
   int index,
   int count,
   IComparer comparer
);
[C++]
public: virtual void Sort(
   int index,
   int count,
   IComparer* comparer
);
[JScript]
public function Sort(
   index : int,
   count : int,
   comparer : IComparer
);

Parameters

index
The starting index of the range to sort.
count
The length of the range to sort.
comparer
The IComparer implementation to use when comparing elements.

-or-

a null reference (in Visual Basic Nothing) to use the IComparable implementation of each element.

Return Value

None.

Exceptions

Exception Type Condition
ArgumentOutOfRangeException index is less than zero.

-or-

count is less than zero.

ArgumentException index and count do not specify a valid range in the ArrayList.
NotSupportedException The ArrayList is read-only.

Remarks

This method can be overridden by a derived class.

See Also

ArrayList Class | ArrayList Members | System.Collections Namespace | ArrayList.Sort Overload List