StringComparer: IComparer;
The StringComparer property returns an object for comparing elements of string type.
Comparison is executed taking into account the length and case of element contents.
Sub UserProc;
Var
Com: IComparer;
i, i1, i2, i3: Integer;
Begin
Com := Comparer.StringComparer;
i := Com.Compare("a", "A");
i1 := Com.Compare("aa", "A");
i2 := Com.Compare("a", "AA");
i3 := Com.Compare("aA", "Aa");
End Sub UserProc;
After executing the example the "i, i1, i2, i3" variables contain the "-1, 1, -1, -1" values respectively.
See also: