编译错误:类型“ASP.global_asax"存在于两个 DLL 中 [英] Compilation Error: The type 'ASP.global_asax' exists in both DLLs

查看:24
本文介绍了编译错误:类型“ASP.global_asax"存在于两个 DLL 中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚将另一个项目页面及其 dll 集成到我现有项目的 Bin/文件夹中.我的项目框架是 3.5.当我尝试构建项目或解决方案时,它抛出以下错误:

I have just integrated another project pages and its dlls into my existing project's Bin/ folder. My project framework is 3.5. When i am trying to build the project or solution, it's throwing following error:

类型 'ASP.global_asax' 存在于 'c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files imesheet15a75c54898b48b9assemblydl358b062b20ceda584_1c9App_global.asax.DLL' 和 'c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files imesheet15a75c54898b48b9App_global.asax.q_h6dbfx.dll' c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files imesheet15a75c54898b48b9App_Web_admin.master.fdf7a39c.zecazgwd.0.cs"

"The type 'ASP.global_asax' exists in both 'c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files imesheet15a75c54898b48b9assemblydl358b062b20ceda54_c98cc801App_global.asax.DLL' and 'c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files imesheet15a75c54898b48b9App_global.asax.q_h6dbfx.dll' c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files imesheet15a75c54898b48b9App_Web_admin.master.fdf7a39c.zecazgwd.0.cs "

在 web.config 中设置batch=false"不起作用.我还尝试从c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files"中删除所有文件夹,然后清理并重建soultion.但是还是不行.

Setting "batch=false" into web.config's is not working. I have also tried to delete all folders from "c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files", then clean and rebuild soultion. But still it's not working.

推荐答案

就我而言,问题发生在虚拟应用程序的 bin 文件夹中.查看这个 bin 文件夹,您可能会看到两个文件(我发现的信息 这里):

In my case the problem occurred in a virtual application's bin folder. Looking into this bin-folder you will probably see two files (an information I found here):

  • App_global.asax.dll
  • App_global.asax.compiled

删除这些可以解决错误.App_global.asax.dll 也是在运行时生成的,这会导致问题.然而,我仍在调查这些文件是如何到达那里的,所以绝对欢迎评论!

Removing these resolves the error. The App_global.asax.dll is generated at runtime too which causes the problem. I am however still investigating how these files got there, so comments are definitely welcome!

这篇关于编译错误:类型“ASP.global_asax"存在于两个 DLL 中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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