I have a simple windows form bound to the parent table -Checks-. This form has a datagridview of the children table -CheckSplits-.
The Dataset has the relationship setup between the parent and child with cascade delete enabled.
When I delete parent record and attempt to save the changes/deletes via the following code:
I receive the following error:
Concurrency violation: the DeleteCommand affected 0 of the expected 1 records.
This happens on the .update of the tblCheckSplits table.
Any thoughts greatly appreciated!!
The Dataset has the relationship setup between the parent and child with cascade delete enabled.
When I delete parent record and attempt to save the changes/deletes via the following code:
VB.NET:
Me.Validate()
Me.TblChecksBindingSource.EndEdit()
Me.TblChecksTableAdapter.Update(Me.CheckWriterDataSet.tblChecks)
Me.TblCheckSplitsBindingSource.EndEdit()
Me.TblCheckSplitsTableAdapter.Update(Me.CheckWriterDataSet.tblCheckSplits)
I receive the following error:
Concurrency violation: the DeleteCommand affected 0 of the expected 1 records.
This happens on the .update of the tblCheckSplits table.
Any thoughts greatly appreciated!!