Skip to main content

TcxValueType.CompareValues(Pointer,Pointer) Method

Compares two values specified by pointers.

Declaration

class function CompareValues(P1: Pointer; P2: Pointer): Integer; virtual;

Parameters

Name Type Description
P1 Pointer

The pointer to the first compared value.

P2 Pointer

The pointer to the second compared value.

Returns

Type Description
Integer

The comparison result. Refer to the Remarks section for details.

Remarks

Call the CompareValues class function to compare values of the type that corresponds to the current TcxValueType class descendant. The class function can return the following values:

Returned Value Description
-1 The P2 value exceeds the P1 value.
0 Values are equal.
1 The P1 value exceeds the P2 value.
See Also