Forum Discussion
john john
Aug 28, 2020Steel Contributor
Why i am unable to use SystemUpdate() inside my CSOM code
I have the following CSOM code inside a console application:-
ListItemCreationInformation itemCreateInfo = new ListItemCreationInformation();
ListItem listItem2 = riskValue.AddItem(itemCreateInfo);
listItem2["Title"] = s;
listItem2.SystemUpdate();
but i am not sure why i can not access the SystemUpdate method, where i am getting this error:-
Severity Code Description Project File Line Suppression State
Error CS1061 'ListItem' does not contain a definition for 'SystemUpdate' and no accessible extension method 'SystemUpdate' accepting a first argument of type 'ListItem' could be found (are you missing a using directive or an assembly reference?)
- john johnSteel Contributor
FedericoPorceddu82i am working on sharepoint online ..
Great! john john can you confirm you are using this package? https://www.nuget.org/packages/Microsoft.SharePointOnline.CSOM/
Cheers,
Federico