简体   繁体   English

自定义Sharepoint 2013页面布局引发错误

[英]Custom Sharepoint 2013 page layout throws error

I'm trying to create a custom page layout for Sharepoint 2013. So far the only changes I've made to the Design Manager template are linking a CSS file (linked within the PlaceHolderAdditionalPageHead section), and added divs, each containing a Web Part zone, to the PlaceHolderMain section. 我正在尝试为Sharepoint 2013创建自定义页面布局。到目前为止,我对Design Manager模板所做的唯一更改是链接CSS文件(在PlaceHolderAdditionalPageHead部分中链接),并添加了div,每个div都包含一个Web部件。区域,放置到PlaceHolderMain部分。 The page layout previews with no problem, but when I try to set it as the layout for an actual Sharepoint page, I get this error: 页面布局预览没有问题,但是当我尝试将其设置为实际Sharepoint页面的布局时,出现此错误:

The DataSourceID of 'TopNavigationMenu' must be the ID of a control of type IHierarchicalDataSource. “ TopNavigationMenu”的DataSourceID必须是IHierarchicalDataSource类型的控件的ID。 A control with ID 'topSiteMap' could not be found. 找不到ID为“ topSiteMap”的控件。

I've tried googling this error, but all the instances of it I can find are caused by custom web parts etc. Does anyone know what could be causing it here? 我尝试使用Google搜索该错误,但是我可以找到的所有实例都是由自定义Web部件等引起的。有人知道这是什么原因吗?

EDIT: I have confirmed I am site collection administrator, and I checked the logs. 编辑:我已经确认我是网站集管理员,并且检查了日志。 They don't mention anything new, but here's the full error from the logs just to be clear: 他们没有提到任何新内容,但是这里有一些完整的日志错误,只是为了清楚起见:

11/19/2014 14:44:02.10 w3wp.exe (0x20C0) 0x2598 SharePoint Foundation General 8nca Medium Application error when access /aa/Pages/default.aspx, Error=The DataSourceID of 'TopNavigationMenu' must be the ID of a control of type IHierarchicalDataSource. 2014年11月19日14:44:02.10 w3wp.exe(0x20C0)0x2598 SharePoint Foundation常规8nca中访问/aa/Pages/default.aspx时出现应用程序错误,错误=``TopNavigationMenu''的DataSourceID必须是控件的ID类型为IHierarchicalDataSource。 A control with ID 'topSiteMap' could not be found. 找不到ID为“ topSiteMap”的控件。 at System.Web.UI.WebControls.HierarchicalDataBoundControl.GetDataSource() at System.Web.UI.WebControls.HierarchicalDataBoundControl.ConnectToHierarchicalDataSource() at System.Web.UI.WebControls.HierarchicalDataBoundControl.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.... 1fbccd9c-39f9-c07e-674b-2ee9a47b3002 在System.Web.UI.WebControls.HierarchicalDataBoundControl.GetDataSource()在System.Web.UI.WebControls.HierarchicalDataBoundControl.ConnectToHierarchicalDataSource()在System.Web.UI.WebControls.HierarchicalDataBoundControl.OnLoad(EventArgs e)在System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control的.Control.LoadRecursive() System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control.LoadRecursive()的System.Web ....的1fbccd9c-39f9-c07e-674b-2ee9a47b3002

11/19/2014 14:44:02.10* w3wp.exe (0x20C0) 0x2598 SharePoint Foundation General 8nca Medium ...UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) 1fbccd9c-39f9-c07e-674b-2ee9a47b3002 2014年11月19日14:44:02.10 * w3wp.exe(0x20C0)0x2598 SharePoint Foundation常规8nca Medium ... UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint,Boolean includeStagesAfterAsyncPoint)1fbccd9c-39f9-c07e-674b-2ee9a47b3002

11/19/2014 14:44:02.10 w3wp.exe (0x20C0) 0x2598 SharePoint Foundation Runtime tkau Unexpected System.Web.HttpException: The DataSourceID of 'TopNavigationMenu' must be the ID of a control of type IHierarchicalDataSource. 2014年11月19日14:44:02.10 w3wp.exe(0x20C0)0x2598 SharePoint Foundation运行时tkau意外的System.Web.HttpException:“ TopNavigationMenu”的DataSourceID必须是IHierarchicalDataSource类型的控件的ID。 A control with ID 'topSiteMap' could not be found. 找不到ID为“ topSiteMap”的控件。 at System.Web.UI.WebControls.HierarchicalDataBoundControl.GetDataSource() at System.Web.UI.WebControls.HierarchicalDataBoundControl.ConnectToHierarchicalDataSource() at System.Web.UI.WebControls.HierarchicalDataBoundControl.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain(Boolea... 1fbccd9c-39f9-c07e-674b-2ee9a47b3002 在System.Web.UI.WebControls.HierarchicalDataBoundControl.GetDataSource()在System.Web.UI.WebControls.HierarchicalDataBoundControl.ConnectToHierarchicalDataSource()在System.Web.UI.WebControls.HierarchicalDataBoundControl.OnLoad(EventArgs e)在System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control的.Control.LoadRecursive() System.Web.UI.Control.LoadRecursive()的System.Web.UI.Control.LoadRecursive()的System.Web.UI.Page.ProcessRequestMain(Boolea ... 1fbccd9c-39f9-c07e-674b的.LoadRecursive() -2ee9a47b3002

11/19/2014 14:44:02.10* w3wp.exe (0x20C0) 0x2598 SharePoint Foundation Runtime tkau Unexpected ...n includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) 1fbccd9c-39f9-c07e-674b-2ee9a47b3002 2014年11月19日14:44:02.10 * w3wp.exe(0x20C0)0x2598 SharePoint Foundation运行时tkau意外... n includeStagesBeforeAsyncPoint,布尔值includeStagesAfterAsyncPoint)1fbccd9c-39f9-c07e-674b-2ee9a47b3002

Turned out the problem was in my master page. 原来问题出在我的母版页上。 I was using Seattle, so I switched to Oslo and the problem went away. 我当时在使用西雅图,所以我切换到奥斯陆,问题就消失了。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM