Update Record in Visual Basic and MS Access Download Free source code

Download
Download is available until [expire_date]
  • Version [version]
  • Download 240
  • File Size 342.71 KB
  • File Count 1
  • Create Date August 7, 2015
  • Last Updated August 7, 2015

Update Record in Visual Basic and MS Access Download Free source code

Update Record in Visual Basic and MS Access Download Free source code

This visual basic 6 program will update the record stored in ms access database.

Before we can update a record, a record must be inserted or saved first, that’s why the program has also an insert sql statement.

Sample code on update function in visual basic 6

Sub UpdateRecord()
If rs.State = adStateOpen Then rs.Close
sql = "Update tblstudent set studentname='" & txtStudentName.Text & "'
, StudentAge=" & txtStudentAge.Text & ", StudentContact=" & txtStudentContact.Text & "
,StudentAddress='" & txtStudentAddress.Text & "'
Where id=" & txtID.Text & ""
rs.Open sql, conn
MsgBox "Record(s) successfully updated", vbInformation, ""
End Sub

You can also download the complete step by step tutorial on how to update a record in visual basic 6 and ms access.

Post navigation