EOF / BOF not really End / Start
Posted: 04.04.2016, 17:09
I am doing some updates on some old D5 stuff with SQLite3 so have to use Zeos 6.
This is not working as expected.
..Click Next until the Last File is in use.
....Click Next again and it displays the Last File again. // Surely it should have be at the last File after the Last Next??
......Click Next and then it will go to the First File in the DB.
Is it me or is this the correct behavior?
It works similarly for the Prior button too.
How do I remove the need for that second click at the end?
This is not working as expected.
..Click Next until the Last File is in use.
....Click Next again and it displays the Last File again. // Surely it should have be at the last File after the Last Next??
......Click Next and then it will go to the First File in the DB.
Code: Select all
procedure TfrmMain.btnNextClick(Sender: TObject);
begin
if dm.tblFiles.EOF then
dm.tblFiles.First else
dm.tblFiles.Next;
end;
It works similarly for the Prior button too.
How do I remove the need for that second click at the end?