Compartilhar via


ListViewWebPart.RestrictedTemplateType Method (SPList)

Determines whether access to the list template of the specified SPList is restricted.

Namespace:  Microsoft.SharePoint.WebPartPages
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
<AspNetHostingPermissionAttribute(SecurityAction.LinkDemand, Level := AspNetHostingPermissionLevel.Minimal)> _
Public Shared Function RestrictedTemplateType ( _
    list As SPList _
) As Boolean
'Usage
Dim list As SPList
Dim returnValue As Boolean

returnValue = ListViewWebPart.RestrictedTemplateType(list)
[AspNetHostingPermissionAttribute(SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
public static bool RestrictedTemplateType(
    SPList list
)

Parameters

Return Value

Type: System.Boolean
true if access to the list template is restricted; otherwise, false.

Remarks

This method uses the value of the BaseTemplate property to determine whether access is restricted. This method returns false if the list is null .

See Also

Reference

ListViewWebPart Class

ListViewWebPart Members

RestrictedTemplateType Overload

Microsoft.SharePoint.WebPartPages Namespace