Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

SPSite.LockIssue property

Gets or sets the comment that is used in locking a site collection.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
[ClientCallablePropertyAttribute(SetProperty = false)]
public string LockIssue { get; set; }

Property value

Type: System.String
A string that contains the comment.

The following code example uses the LockIssue property to explain why a specified site collection is being write-locked.

using (SPSite oSiteCollection = new SPSite("http://Site_Name"))
{
    oSiteCollection.WriteLocked = true;
    oSiteCollection.ReadLocked  = false;
    oSiteCollection.LockIssue   = "Customer did not pay bill.";
}
NoteNote

Certain objects implement the IDisposable interface, and you must avoid retaining these objects in memory after they are no longer needed. For information about good coding practices, see Disposing Objects.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.