TDataSetEnumerator class
Enumerator for
TDataset records.
Declaration
TDataSetEnumerator = classDescription
TDataSetEnumerator is an enumerator for the records in a dataset.
It returns the
Fields instance. It navigates from the first till the last record in the dataset.
The following is an example of how this can be used, in conjunction with the field enumerator:
var
Rec : TFields;
Fld : TField;
begin
for Rec in MyDataset do
for F in Rec do
Writeln(F.Name,' : ',F.AsString);
Note that the current record pointer of the dataset is modified as the loop is traversed. If the current record is modified by other code while the loop is running, the result may become unpredictable. Similarly, if 2 enumerators are used simultaneously for the same dataset, the results are unpredictable.
See also
Properties
Current | public | Current record. |
Methods
Create | public | Create a new instance of the dataset enumerator. |
MoveNext | public | Attempts to navigate to the next record. |
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
