Skip to main content

TcxCustomDataController.RestoreKeys Method

Restores the record identifiers of the expanded master rows, grouping rows and selected rows.

Declaration

procedure RestoreKeys;

Remarks

Use the RestoreKeys method to restore the record identifiers of the master rows, grouping rows and selected rows. Unlike record handles and indexes, record identifiers are not changed when the number and order of records within a dataset changes (see the TcxCustomDataSource class description for information on record indexes and record handles).

The record identifiers are generated via the GetRecordId method which accepts a record handle as its parameter.

Call the RestoreKeys method after making changes to a dataset (for instance, before deleting a record). This will restore the expansion and selection state within the data controller when changing the order of records within the associated dataset. Call the SaveKeys method to save a record’s state.

See Also