无法加载程序集“App_Web_kh7-x3ka”? [英] Could not load the assembly 'App_Web_kh7-x3ka' ?

查看:86
本文介绍了无法加载程序集“App_Web_kh7-x3ka”?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将我的网站发布到我的服务器,当我尝试运行它时,我得到以下异常:



无法加载程序集App_Web_kh7-x3ka。

解决方案

看起来像动态创建的程序集的名称。例如。当你使用XMLSerialization时,会在运行时创建一个dll,其中包含用于此目的的代码。

现在,该dll的创建失败(用户无权执行csc.exe)或加载新生成的dll失败,这可能是由于病毒扫描程序仍在仔细检查它或安全设置。

因此检查服务器的安全设置是否允许IIS生成程序集并加载这些程序集。 / blockquote>

<%@   Page     />    标记   你将   可能   参见       属性   喜欢:  



inherits = < span class =code-keyword> yourPageClass,App_Web_kh7-x3ka



删除 App_Web_XXXX part add CodeFile 属性 指向 to your 代码 后面 file:

< span class =code-attribute>

CodeFile = yourPageFile.aspx.cs

I publish my website to my server and when I try to run it I get the following exception:

Could not load the assembly 'App_Web_kh7-x3ka'.

解决方案

Looks like the name of a dynamically created assembly. E.g. when you use XMLSerialization, a dll is created at runtime which contains the code for that purpose.
Now, either the creation of that dll failed (user has no rights to execute csc.exe), or loading the freshly generated dll failed which could be due to a virus scanner still scrutinizing it, or security settings.
Hence check that the security settings of the server allow IIS to generate assemblies and to load those assemblies.


On the first line of your aspx page within the <%@Page /> tag you’ll probably see an attribute like:



inherits="yourPageClass, App_Web_kh7-x3ka".



Delete the "App_Web_XXXX" part and add the CodeFile attribute pointing to your code behind file:



CodeFile="yourPageFile.aspx.cs"


这篇关于无法加载程序集“App_Web_kh7-x3ka”?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆