I`ve put together a flashcard app which works reasonably well but I`m also wanting to sequentially go through the records, for example to edit etc.
I`ve stored all the fields in sqlite but having a problem with accessing the first sqlite row!
For example, to go back through the records sequentially I`ve put together this code:
Code: Select all
on mouseup
put tRecordNumber - 1 into tRecordNumber
if tRecordNumber <= 1 then
put 1 into tRecordNumber
end if
openDB
put "SELECT Question, Answer, _ROWID_, Tag FROM FC" & CR & "LIMIT 1 OFFSET '"&tRecordNumber&"'" into tSQL
put revdb_querylist(,,gConID,tSQL) into tList
set itemdelimiter to tab
put item 1 of tList into fld"Front"
put item 2 of tList into fld"Back"
put item 3 of tList into fld"RowID"
put item 4 of tList into fld"Tag"
closeDB
end mouseup
Not sure why I can`t access the first record of sqlite using the above code??
Grateful for any tips on what I`m doing wrong!
Many thanks,
Glenn