I have a class that creates a dataset and dataadapter.
When the user updates a Windows form, I want the dataadapter to update the DB of course. The code runs without an error , but the database does not get updated.
here is where the Dataadapter is created:
Me.EmployeeDA = New SqlDataAdapter("SelectedEmployee",
'Dim SELECTED As New DataSet
.MissingSchemaAction = MissingSchemaAction.AddWithKey
.SelectCommand.CommandType = CommandType.StoredProcedure
no errors there and the dataset gets filled with exactly one row as it should.
Ok, edit the current data in the dataset
Dim drCurrent As DataRow
drCurrent = oEmployee.SELECTED.Tables(0).Rows.Find(empID)
drCurrent("Title") = oEmployee.Title
OK , send the changes back to the Database
this all runs without error, but the database does not update.
is this code correct, or am i missing something?