Attached is a program, that I am having a problem in using the Sqlite update command. The update command starts at line 241. The code for line 241 is below.
i = Msgbox ("Do You want to Save the Data?","Save Data",cMsgboxYesNo,cMsgBoxExclamation)
If i = cYes Then
text = "update Customer set ccontact = '" &TextBoxc8.Text&"' where ROWID = "&recnum
cmd.CommandText = text
cmd.ExecuteNonQuery
End If
As you can see, I am using rowid to save the data. At the present time I am only trying to save the Customer contact data.
The program sometime saves the data the first time, however any record that is saved thereafter does not get saved. The data appears to be saved if you go back into the record you just saved. However if you exit the program and then re-run it and look at that record again the data is not there.
So could someone please take a look and see what I am doing wrong.
One other item, if you try to click on the same record again that you just saved the event does not fire. You have to click another record and display it before you can go back and click the record you saved.
Thanks
i = Msgbox ("Do You want to Save the Data?","Save Data",cMsgboxYesNo,cMsgBoxExclamation)
If i = cYes Then
text = "update Customer set ccontact = '" &TextBoxc8.Text&"' where ROWID = "&recnum
cmd.CommandText = text
cmd.ExecuteNonQuery
End If
As you can see, I am using rowid to save the data. At the present time I am only trying to save the Customer contact data.
The program sometime saves the data the first time, however any record that is saved thereafter does not get saved. The data appears to be saved if you go back into the record you just saved. However if you exit the program and then re-run it and look at that record again the data is not there.
So could someone please take a look and see what I am doing wrong.
One other item, if you try to click on the same record again that you just saved the event does not fire. You have to click another record and display it before you can go back and click the record you saved.
Thanks