Latest Posts

When modifying a list item, what is the main difference between using SPListItem.Update() and SPListItem.SystemUpdate()?

SPListItem.Update() SPListItem.SystemUpdate()
New version gets created of the Item We can retain the same version of the item using this method
Modified and Modified By fields will be updated after using this method We can retain the value of Modified and Modified By columns
Syntax:
listItem.Update();

Syntax:
(1) listItem.SystemUpdate();

  • Updates list item without changing Modified and Modified By fields value
  • Version of the list item is NOT increased

(2) listItem.SystemUpdate(true);

  • Updates list item without changing Modified and Modified By fields value
  • Version of the list item is increased

(3) listItem.SystemUpdate(false);

  • Updates list item without changing Modified and Modified By fields value
  • Version of the list item is NOT increased  

NOTE: listItem.SystemUpdate() = listItem.SystemUpdate(false)

We value your Feedback:

Page URL:

Name:

Email:


Suggestion:

© 2024 Code SharePoint