Sharepoint Forum

 
Home » Forum » Sharepoint       Ask a questionRSS Feeds

Deploying PageLayouts using Features

  Asked By: Madhavi Munim         Date: Apr 10, 2009      Category: Sharepoint      Views: 479
 

I am trying to deploy a pagelayout using a feature using the following Module definition (I took the definition from the PublishingLayouts Feature)


<Module Name="MyPageLayouts" Url="_catalogs/masterpage" Path="MasterPages" RootWebOnly="TRUE">
<File Url="MyPageLayout.aspx" Type="GhostableInLibrary">
<Property Name="Title" Value="My Pagelyout" />
<Property Name="MasterPageDescription" Value="Hello" />
<Property Name="ContentType" Value="Page Layout" />
<Property Name="PublishingPreviewImage" Value="/_catalogs/masterpage/en-US/Preview Images/ArticleLeft.png, /_catalogs/masterpage/en-US/Preview Images/ArticleLeft.png" />
<Property Name="PublishingAssociatedContentType" Value=";#MyContentType;#0x010100C568DB52D9D0A14D9B2FDCC96666E9F2007948130EC3DB064584E219954237AF39004A85D16F25DBAB4B90209212164607680101#;" />
</File>
</Module>

The PageLayout shows up in the MasterPage gallery, but when i try to edit or view properties on the PageLayout i recieve the following error in the log:

03/05/2007 14:11:45.02 w3wp.exe (0x0D24) 0x14E4 Windows SharePoint Services General 8sl1 High DelegateControl: Exception thrown while adding control 'ASP._controltemplates_publishingconsole_ascx': System.IndexOutOfRangeException: Index was outside the bounds of the array. at Microsoft.SharePoint.SPFieldMultiColumnValue.TryParseMultiColumnValue(String fieldValue, DelimiterType delimiterType, List`1& subColumnValues) at Microsoft.SharePoint.SPFieldMultiColumnValue.ParseMultiColumnValue(String fieldValue, DelimiterType delimiterType) at Microsoft.SharePoint.SPFieldMultiColumnValue.ParseMultiColumnValue(String fieldValue) at Microsoft.SharePoint.SPFieldMultiColumnValue..ctor(String fieldValue) at Microsoft.SharePoint.Publishing.Fields.ContentTypeIdFieldValue..ctor(String value) at Microsoft.SharePoint.Publishing.Fields.ContentTypeIdFieldType.GetFieldValue(String...
03/05/2007 14:11:45.02* w3wp.exe (0x0D24) 0x14E4 Windows SharePoint Services General 8sl1 High ... value) at Microsoft.SharePoint.SPListItem.ValueFromSafeArrayObject(Object obj, SPField fld) at Microsoft.SharePoint.SPListItem.GetValue(SPField fld, Int32 columnNumber, Boolean bRaw) at Microsoft.SharePoint.SPListItem.get_Item(Guid fieldId) at Microsoft.SharePoint.Publishing.CachedListItem.GetValueByIndex(SPListItem item, FieldMetaData field) at Microsoft.SharePoint.Publishing.CachedListItem..ctor(SPListItem item, SPListItem alternateItem, NodeTypes nodeType, String id, String parentId, String title, String url, String description, CachedObjectFactory factory, List`1& fieldInfo) at Microsoft.SharePoint.Publishing.CachedListItem.CreateCachedListItem(SPListItem item, SPListItem alternateItem, Boolean parentIsWeb, CachedObjectFactory factory, List`1& fieldInfo) at...
03/05/2007 14:11:45.02* w3wp.exe (0x0D24) 0x14E4 Windows SharePoint Services General 8sl1 High ... Microsoft.SharePoint.Publishing.CachedObjectFactory.CreateListItemFromUrl(String url, SPWeb contextWeb, Boolean enableCheckedOutItem) at Microsoft.SharePoint.Publishing.WebControls.ConsoleUtilities.get_ContextualListItemCached() at Microsoft.SharePoint.Publishing.WebControls.ConsoleUtilities.IsDocLibListItem() at Microsoft.SharePoint.Publishing.WebControls.ConsoleUtilities.GetContextualFormModeFromPostedForm() at Microsoft.SharePoint.Publishing.WebControls.ConsoleDataSource.OnInit(EventArgs e) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.InitRecursive(Control namingContainer) at Syste...
03/05/2007 14:11:45.02* w3wp.exe (0x0D24) 0x14E4 Windows SharePoint Services General 8sl1 High ...m.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.AddedControl(Control control, Int32 index) at System.Web.UI.ControlCollection.Add(Control child) at Microsoft.SharePoint.WebControls.DelegateControl.AddControlResilient(Control ctl)

I appears that sharepoint is trying to parse a multicolumn value, and that fails



Can anybody tell me what i am doing wrong?


Do you know someone who can help? Share a link to this thread on twitter, or facebook.

Tagged:        

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on Deploying PageLayouts using Features Or get search suggestion and latest updates.


Your Answer
  • Answer should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].