[嗨,我有kentico 11网站。尝试托管并从IIS在本地运行它时出现以下错误
Server Error in '/' Application.
No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: Castle.MicroKernel.ComponentNotFoundException: No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found
Source Error:
Line 16: protected override void OnPreRender(EventArgs e)
Line 17: {
Line 18: base.OnPreRender(e);
Line 19:
Line 20: lblText.Text = "The web site doesn't contain any content. Sign in to <a href=\"" + ResolveUrl("~/Admin/cmsadministration.aspx") + "\">administration</a> and edit the content.";
Source File: \CMS\Default.aspx.cs Line: 18
Stack Trace:
[ComponentNotFoundException: No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found]
Castle.MicroKernel.DefaultKernel.Castle.MicroKernel.IKernelInternal.Resolve(Type service, Arguments arguments, IReleasePolicy policy, Boolean ignoreParentContext) +144
Castle.MicroKernel.DefaultKernel.Resolve(Type service, Arguments arguments) +40
Castle.Windsor.WindsorContainer.Resolve() +69
CMS.Core.IoCContainer.Resolve() +93
[ServiceResolutionException: Resolution of 'CMS.Helpers.ICurrentCookieLevelProvider' failed with the following error: No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found]
CMS.Core.IoCContainer.Resolve() +262
CMS.Helpers.CookieHelper.IsCookieAllowedInternal(String name) +38
CMS.Helpers.CookieHelper.GetValueInternal(String name, Boolean useDefaultValue, Boolean allowSensitiveData) +397
CMS.DocumentEngine.DocumentContext.GetCurrentStylesheet(PageInfo pageInfo) +87
CMS.UIControls.DocumentBase.get_CurrentStylesheet() +31
CMS.UIControls.DocumentBase.SetCSS() +21
CMS.UIControls.DocumentBase.PreRender() +44
_Default.OnPreRender(EventArgs e) in \CMS\Default.aspx.cs:18
System.Web.UI.Control.PreRenderRecursiveInternal() +132
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4005
任何帮助都非常有用。
类似某些CMS库可能会丢失。您如何设置网站:您是否安装了Kentico或获得了代码和数据库备份?在Visual Studio的CMS项目中检查丢失的引用,清理,重建并重试。