SPSecurity.RunWithElevatedPrivileges(delegate() {
oWeb.AllowUnsafeUpdates = true; SPList oList = oWeb.Lists[sRequestList]; SPListItem oVoucher = oList.GetItemById(Convert.ToInt32(Request.QueryString["RequestNo"])); oVoucher.Delete();
oList.Update(); oWeb.AllowUnsafeUpdates = false;
});
Saturday, 25 April 2015
Delete list item programmatically by id
Labels:
c#,
delete item,
sharepoint list

Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment