This error "The security validation for this page is invalid. Click Back in your Web browser, refresh the page, and try your operation again" is very common for beginners SharePoint developer, who start developing and digging into SharePoint object model, it’s coming while updating SharePoint list, the cause of error is due to security rights, if we make web.AllowUnsafeUpdates = true and then update the SharePoint list then we won’t get above error.
Sample Code:
Web.AllowUnsafeUpdates = true;
item["Title"]=”Sample”;
item.Update();
Happy Coding !!
Showing posts with label The security validation for this page is invalid. Click Back in your Web browser. Show all posts
Showing posts with label The security validation for this page is invalid. Click Back in your Web browser. Show all posts
Monday, July 20, 2009
Error while updating SharePoint list, “The security validation for this page is invalid. Click Back in your Web browser, refresh the page, and try your operation again”
Labels:
and try your operation again,
list item update,
MOSS 2007,
Personal Experience,
refresh the page,
SharePoint,
SharePoint List,
SharePoint Object Model,
The security validation for this page is invalid. Click Back in your Web browser,
web.AllowUnsafeUpdates
Subscribe to:
Posts (Atom)