When running the code below I get the error seen below at the Update() line. What I get out of the message is that the Update() is not valid and having something to do with the row that was modified. I am unable to see why my Update() is not valid. There are other places in my code that I use this same methodology with no problems, which tells me that the problem might well be upstream in the code. However, I have looked at everything I can think of and cannot figure out why this is occurring. Can someone explain to me what constitutes a valid Update() and why mine is not?
This code is run from a double-click event from a datagridview and is supposed to change some values in columns in the row selected in the event, then redisplay the DGV without the row that was changed.
Additionally, I am using SQL as the database and am aware that the problem could be around using True instead of 1, which I have tested and there is no change in the issue.
Can anyone explain to me where I went wrong and how I might be misreading the error?
Code:'Remove Approver from list 'LnkChangeApproveTableAdapter.FillByChangeID(Me._MasterBase_1_0DataSet.lnkChangeApprove, glbintChangeID) CType(frmSignList.lnkChangeApproveBindingSource.Current, DataRowView).Item("chrSignature") = CStr("Removed by Change Admin, " & glbstrAdmin & " " & CStr(DateAndTime.Now)) CType(frmSignList.lnkChangeApproveBindingSource.Current, DataRowView).Item("blnRemove") = 1 frmSignList.Validate() frmSignList.lnkChangeApproveBindingSource.EndEdit() frmSignList.LnkChangeApproveTableAdapter.Update(frmSignList._MasterBase_1_0DataSet) frmSignList.LnkChangeApproveTableAdapter.FillByChangeID(frmSignList._MasterBase_1_0DataSet.lnkChangeApprove, glbintChangeID) 'refresh DGV Dim LoadAdminList As New nspSignList.SignOperation LoadAdminList.ChangeAdminOperation()![]()




Reply With Quote
