我在 Visual Studio 2010 中为 SharePoint 2010 站点定义了站点,它具有多项功能。通过 powershell 部署站点时,所有功能都已正确激活,但发生了一个有趣的事件——功能中的接收器显然无法触发。
当我手动停用某个特定功能并尝试再次激活它时,我收到以下错误:
File specified in the modules section of this template already exists.
我试过了http://zimmergren.net/technical/sp-2010-find-error-messages-with-a-correlation-id-token-in-sharepoint-2010了解有关错误的更多信息,但无法真正找出引发错误的文件。
请您参考如下方法:
听起来您需要将功能的 elements.xml 中的 IgnoreIfAlreadyExists 属性设置为 True。
<File Path="Style Library\whatever.png" Type="GhostableInLibrary" IgnoreIfAlreadyExists="true" />
希望对你有帮助。
