Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Checks whether the site has a policy applied.
Namespace: Microsoft.SharePoint.Client.InformationPolicy
Assembly: Microsoft.Office.Client.Policy (in Microsoft.Office.Client.Policy.dll)
Syntax
'Declaration
Public Shared Function DoesProjectHavePolicy ( _
context As ClientRuntimeContext, _
web As Web _
) As ClientResult(Of Boolean)
'Usage
Dim context As ClientRuntimeContext
Dim web As Web
Dim returnValue As ClientResult(Of Boolean)
returnValue = ProjectPolicy.DoesProjectHavePolicy(context, _
web)
public static ClientResult<bool> DoesProjectHavePolicy(
ClientRuntimeContext context,
Web web
)
Parameters
- context
Type: Microsoft.SharePoint.Client.ClientRuntimeContext
web
Type: Microsoft.SharePoint.Client.WebThe site.
Return value
Type: Microsoft.SharePoint.Client.ClientResult<Boolean>
true if there is a policy applied on the site; otherwise, false.
Exceptions
| Exception | Condition |
|---|---|
| ArgumentNullException | The web parameter is a null reference (Nothing in Visual Basic). |