TcxCustomDataSource.GetInfoForCompare(TcxDataRecordHandle,TcxDataItemHandle,PAnsiChar) Method
Locates data in memory for a specific record/column.
Declaration
function GetInfoForCompare(ARecordHandle: TcxDataRecordHandle; AItemHandle: TcxDataItemHandle; var PValueBuffer: PAnsiChar): Boolean; virtual;
Parameters
Name | Type |
---|---|
ARecordHandle | TcxDataRecordHandle |
AItemHandle | TcxDataItemHandle |
PValueBuffer | PAnsiChar |
Returns
Type |
---|
Boolean |
Remarks
The GetInfoForCompare method allows you to implement a faster comparison operation for values in a custom data source. In this instance, you must also override the IsNativeCompare function which returns True.
The ARecordHandle parameter identifies the record handle (a unique identifier of a record) in the current data source. The AItemHandle parameter determines the item handle (a value that uniquely identifies the column and thus the field from which to return the text to display). See the TcxCustomDataSource class to obtain detailed information on record and item handles.
Before calling GetInfoForCompare, the GetRecordHandleByIndex and GetItemHandle methods are invoked. They return the record handle and the item handle respectively which are passed as arguments to the GetInfoForCompare method.
The GetInfoForCompare method returns the pointer in memory at which the value for a specific record/column is located. The comparison procedure determines the type of values to compare by reading the TcxGridColumn.DataBinding.ValueTypeClass property.
The function returns True if the pointer to a specific value is located. Otherwise, it returns False.