List
if (properties.ListTitle == "Project")
{
properties.Cancel = true;
}
Site
public override void WebDeleting(SPWebEventProperties properties)
{
properties.Status = SPEventReceiverStatus.CancelWithError;
properties.ErrorMessage = "This site unable to deleted.";
properties.Cancel = true;
}
if (properties.ListTitle == "Project")
{
properties.Cancel = true;
}
Site
public override void WebDeleting(SPWebEventProperties properties)
{
properties.Status = SPEventReceiverStatus.CancelWithError;
properties.ErrorMessage = "This site unable to deleted.";
properties.Cancel = true;
}
No comments:
Post a Comment