我有一个C# asmx服务项目,原本是在framework 2和vs 2008下运行的,现在我把它更新到了framework 4和vs 2010。
当我以debug模式构建dll时,它可以成功编译,但是当我以release模式构建时,就会出现以下错误:
Error 51 Mixed mode assembly is built against version 'v1.1.4322' of the runtime and cannot be loaded in the 4.0 runtime without additional configuration information. C:\Service\MycService\SGEN
更新: 好吧,我从项目属性中更改了框架为3.5,以release模式构建成功了,但是在4.0框架中有什么问题呢?我需要它能在4.0框架下正常工作。
当我以debug模式构建dll时,它可以成功编译,但是当我以release模式构建时,就会出现以下错误:
Error 51 Mixed mode assembly is built against version 'v1.1.4322' of the runtime and cannot be loaded in the 4.0 runtime without additional configuration information. C:\Service\MycService\SGEN
更新: 好吧,我从项目属性中更改了框架为3.5,以release模式构建成功了,但是在4.0框架中有什么问题呢?我需要它能在4.0框架下正常工作。