RAD Studio VCL Reference
TDataSet.CurrentRecord Property

Indicates the index of the current record in the internal cache of record buffers.

property CurrentRecord: Integer;
__property int CurrentRecord;

Most TDataSet descendants maintain an internal cache of records from the underlying database table. For example, if the dataset is used to populate a data-aware grid, the cache includes a record for each row in the grid. CurrentRecord indicates the offset in this cache of the record buffer for the current record. 

The current record is the record currently in use by the dataset. This can differ from the active record (which the end user sees as active) when the dataset performs operations involving other records. For example, when painting a data-aware grid, CurrentRecord cycles through all the visible records, while ActiveRecord remains constant.

Note: For unidirectional datasets, CurrentRecord is meaningless.


Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!