Difference between splistitem. systemupdate and splistitem. Update Method

Source: Internet
Author: User

Http://www.codegain.com/articles/sharepoint/developmentprogramming/what-is-the-difference-between-splistitem-systemupdate-and-splistitem-update-method.aspx

Splistitem. systemupdate:

Updates
The database (Sharepoint list) with changes that are made to the list
Item, without processing ting changes in the modified time or modified
Fields.

Splistitem. systemupdate overloaded method:

Splistitem. systemupdate ():
Updates the database with changes made to the list item, without changing changes in the modified or modified by fields.

Splistitem. systemupdate (Boolean ):
Updates
The database with changes that are made to the list item,
Changing ting changes in the modified time or modified by fields, or
Optionally, the item version.

Example:

{Codecitation class = "Brush: XML;Gutter: true; "width =" pixel PX "}

// Take the reference of that item

Splistitem listitem = listitemcoll [icount];

Listitem ["first_name"] = "Amit ";

Listitem ["last_name"] = "Kumar ";

Listitem ["email_addr"] = "mcapassion [at] gmail.com ";

// Update the item

Listitem. systemupdate (false );

{/Codecitation}

The argument false informs the SP object model not increment versions.

Splistitem. Update:

Splistitem. Update ():
Updates
The database (Sharepoint list) with changes that are made to the list
Item/New version of item, and changes in the modified time or modified
By fields.

Example:

{Codecitation class = "Brush: XML;Gutter: true; "width =" pixel PX "}

// Take the reference of that item

Splistitem listitem = listitemcoll [icount];

Listitem ["first_name"] = "Amit ";

Listitem ["last_name"] = "Kumar ";

Listitem ["email_addr"] = "mcapassion [at] gmail.com ";

// Update the item

Listitem. Update ();

{/Codecitation}

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.