This is snippet code causes error HRESULT 0x80040E14 when calling SPListItem.Update method
SPList docApprovalList = _web.Lists[List.DocumentApprovalList];
SPListItem itemUpdate = docApprovalList.GetItemById(documentApprovalListObj.Id);
//itemUpdate[SPBuiltInFieldId._Identifier] = documentApprovalListObj.Id;
itemUpdate["ID"] = documentApprovalListObj.Id;
itemUpdate["Status"] = documentApprovalListObj.Status;
itemUpdate.Update();
Solve:
DO NOT change or re-assign value of field ID of list item
0 comments :
Post a Comment