Export (0) Print
Expand All

PublishingWeb.AllowAllWebTemplates method

Resets the available Web templates on this PublishingWeb object to the complete set of Web templates.

Namespace:  Microsoft.SharePoint.Publishing
Assembly:  Microsoft.SharePoint.Publishing (in Microsoft.SharePoint.Publishing.dll)

public void AllowAllWebTemplates(
	bool resetAllSubsitesToInherit
)

Parameters

resetAllSubsitesToInherit
Type: System.Boolean

This Boolean parameter indicates whether the available Web templates should be pushed down to all subsites.

ExceptionCondition
[Microsoft.SharePoint.SPException]

The available Web template property pushdown failed for some Web sites.

[System.UnauthorizedAccessException]

The current user does not have sufficient permissions to perform this action.

After calling this method, the GetAvailableWebTemplates method returns the complete set of Web templates for a given language. The IsInheritingAvailableWebTemplates property is set to false. The IsAllowingAllWebTemplates property is set to True.

After calling this method, you should call the Update method to save changes.

NoteNote

This operation is synchronous.

Show:
© 2014 Microsoft