You probably need your sql to be like this:If ComboBox2.Text = "25" Thensql = "UPDATE OwnerChangesArchive SET BornDayNew = 25 WHERE Id = " & LastRowcmd = New OleDb.OleDbCommand(sql, con)cmd.ExecuteNonQuery()End If
But, that is rather inflexible. You probably want to make it something like this:sql = "UPDATE OwnerChangesArchive SET BornDayNew = " & ComboBox2.Text & " WHERE Id = " & LastRowcmd = New OleDb.OleDbCommand(sql, con)cmd.ExecuteNonQuery()