This code used to work prior to version 2.2.
I found when adding a new row directly to a DGV it was not adding it to the bound data table so I had to programatically add the data to the table using the code below
//Underlying datable does not contain new row so we have to add it
DataRow NR = dtTest.NewRow();
for (int j = 0; j < dgvTest.Columns.Count; j++)
NR[j] = dgvTest[j, e.RowIndex].Value;
dtTest.Rows.Add(NR); //Adds two rows to data table why?
dtTest.RejectChanges(); //removes duplicate – Fails here now – workaround to remove extra row if commented out two rows added
dm.Update(dtTest, “updEmps”, “”, 46);
Thanks for your help
Please login first to submit.