It works at first (it appears to have saved according to a ListBox) but when I close the project (when testing) and reopen it, it has not saved (listbox shows previous value). Can anyone help please?
It doesn’t give an error when the first line is uncommented however it still has the same result- not saving in the SQLite database.
'gDatabase.SQLExecute("begin")
Dim record As RecordSet=gDatabase.SQLSelect("SELECT * From Login")
if record<>nil then
record.MoveFirst
while not record.EOF
if record.Field("Coach").IntegerValue=0 then
if InTeam(record.Field("RunnerID").IntegerValue) then
if record.Field("Team").IntegerValue=0 then
record.Edit
record.Field("Team").IntegerValue=1
record.Update
end
else
if record.Field("Team").IntegerValue=1 then
record.Edit
record.Field("Team").IntegerValue=0
record.Update
end
if record.Field("Team").IntegerValue=2 then
record.Edit
record.Field("Team").IntegerValue=3
record.Update
end
end
end
record.MoveNext
wend
end
gDatabase.Commit
if gDatabase.Error then
MsgBox("ERROR: "+gDatabase.ErrorMessage)
end
Thank you.