الخطأ في الكود الخاص بك هو أن كلمة Password كلمة محجوزة في لغة الاستعلام ولو وضعتها بين معكوفتين [] لازال الاشكال
End Try
كود :
Try
Dim dbsource As String = "Provider=Microsoft.Jet.OLEDB.4.0;" & "Data Source=" & Application.StartupPath & "\database\Database112.mdb"
Dim conn = New OleDbConnection(dbsource)
Dim updatee As String = "Update Users set username ='" & TextBox1.Text & "', [password] = '" & TextBox2.Text & "', gender ='" & ComboBox1.SelectedItem.ToString & "', birthday ='" & DateTimePicker1.Value & "', Address ='" & TextBox3.Text & "', Health_Status ='" & TextBox4.Text & "', password_open_case ='" & TextBox5.Text & "' where user_id=" & My.Settings.deleted.ToString() & ";"
Dim cmd As New OleDbCommand(updatee, conn)
conn.Open()
cmd.ExecuteNonQuery()
MsgBox("save success")
conn.Close()
Catch ex As Exception
MsgBox("error")
