EPUB | CHM | PDF

TDataSet.Methods.Next

Top Previous Next

Positions the cursor on the next record in the dataset.

Syntax:

procedure Next;

Description:

Call Next to position the cursor on the next record in the dataset and make it the active record. Next posts any changes to the active record and:

Sets the Bof and Eof properties to False.

Fetches the next record, positions the cursor on it, and makes it the active record.

Fetches any additional records required for display, such as those needed to fill out a grid control.

Sets the Eof property to True if the cursor was already on the last record in the dataset.

Broadcasts the record change so that data controls and linked detail sets can update.

note TDataSet uses internal, protected methods to position the database cursor and to fetch additional records required for display. In TDataSet, these internal methods are abstract. Descendant classes implement these methods to enable the Next method to work.

See also: Example: Min, Max, Position, RecordCount, First, Next