StringCompareTo Method (Object) |
Compares this instance with a specified
Object and indicates whether this instance precedes, follows, or appears in the same position in the sort order as the specified
Object.
Namespace: SystemAssembly: mscorlib (in mscorlib.dll) Version: 4.0.0.0
Syntax public int CompareTo(
Object value
)
Parameters
- value
- Type: SystemObject
An object that evaluates to a String.
Return Value
Type:
Int32A 32-bit signed integer that indicates whether this instance precedes, follows, or appears in the same position in the sort order as the
value parameter.Value Condition Less than zero This instance precedes
value. Zero This instance has the same position in the sort order as
value. Greater than zero This instance follows
value.-or-
value is null.
Exceptions See Also