1

我正在使用的用户控件在我的 umbraco 上运行良好,即安装在本地机器上,但是当我将它上传到 azure 网站上时,用户控件显示如下错误

  Error reading usercontrols/MdriveReg.ascx

    The following list shows the Public Properties from the Control. By checking the Properties and click the "Save Properties" button at the bottom, umbraco will create the corresponding Macro Elements.




       System.Web.HttpParseException (0x80004005): Could not load type 'MdriveUmbraco.MdriveReg'. ---> System.Web.HttpParseException (0x80004005): Could not load type 'MdriveUmbraco.MdriveReg'. ---> System.Web.HttpException (0x80004005): Could not load type 'MdriveUmbraco.MdriveReg'. at System.Web.UI.TemplateParser.GetType(String typeName, Boolean ignoreCase, Boolean throwOnError) at System.Web.UI.TemplateParser.ProcessInheritsAttribute(String baseTypeName, String codeFileBaseTypeName, String src, Assembly assembly) at System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary parseData) at System.Web.UI.TemplateParser.ProcessException(Exception ex) at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath) at System.Web.UI.TemplateParser.ParseInternal() at System.Web.UI.TemplateParser.Parse() at System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType() at System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider) at System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders() at System.Web.Compilation.BuildProvidersCompiler.PerformBuild() at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) at System.Web.Compilation.BuildManager.GetVPathBuildResult(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean ensureIsUpToDate) at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath) at umbraco.developer.assemblyBrowser.Page_Load(Object sender, EventArgs e)
4

2 回答 2

0

我不是 Azure 专业人士,但它看起来无法加载您的用户控件正在引用的程序集(MdriveUmbraco.dll?)。

该程序集是否存在于网站的 bin 文件夹中?也许它在您本地机器的 GAC 中,因此在那里没有问题?

程序集是否需要签名才能在 Azure 中运行?也许你需要签名?

于 2012-09-24T21:06:41.467 回答
0

问题是我的 .dll 文件没有正确加载,所以我创建了一个新项目,将其编码为我的要求,然后我构建它并将其放入我在 windows azure 中运行的 umbraco 中,它可以正常工作。

问题出在我的 .dll 文件上

于 2012-09-26T05:45:15.173 回答