I'm getting random DBConcurrencyException messages when deleting a row. I noticed that this happens for the rows that I have recently added: this doesn't happen for each row but kind of randomly. I'm working on the main thread using the dataset and dataadapter, so there's no simultaneous update of the data.
I'm using an untyped dataset and the update, delete and insert commands have been generated by the CommandBuilder.
Here's the code I use for the Update
public void UpdateClipboardHistory() {
DataTable changes = dsAllData.Tables[TABLE_CLIPBOARD_HISTORY].GetChanges();
if (changes != null) {
clipDataAdapter.Update(dsAllData.Tables[TABLE_CLIPBOARD_HISTORY]);
}
}
Any idea of why this happens?
Thanks.
Andrea