Provisioning a SharePoint 2010 List Instance Causes Exception in a Site Scoped Feature


Provisioning a list using the ListInstance element causes an exception, if the element is included in a Site scoped feature and the RootWebOnly attribute is set to TRUE.

Setting RootWebOnly to FALSE, or removing the attribute, works as expected.

<ListInstance Title="Balancesheet Status Indicators"
				Description="Status Indicator List for the Balancesheet BI Report"
				Url="Lists/Balancesheet Status Indicators"
				TemplateType="432"
				FeatureId="065c78be-5231-477e-a972-14177cc5b3c7"
				OnQuickLaunch="FALSE"
				RootWebOnly="TRUE" />

If the ListInstance element, as shown above, is included in a Web scoped feature, it works as expected.

Published by

Phil Harding

SharePoint Consultant, Developer, Father, Husband and Climber.

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.