错误CS1705:"后者具有更高版本比引用的程序集和QUOT; [英] Error CS1705: "which has a higher version than referenced assembly"
问题描述
我一直在寻找到这了一下,现在并没有得到它解决。我收到以下错误信息:
I've been looking into this for a bit now and haven't gotten it resolved. I get the following error message:
Compiler Error Message: CS1705: Assembly 'My.Model, Version=1.1.4422.23773, Culture=neutral,
PublicKeyToken=bfde95ba233094b2' uses
'Common, Version=3.3.4273.24368, Culture=neutral, PublicKeyToken=bfde95ba233094b2'
which has a higher version than referenced assembly
'Common, Version=3.3.4269.17112, Culture=neutral, PublicKeyToken=bfde95ba233094b2'
c:\WINDOWS\assembly\GAC_MSIL\Common\3.3.4269.17112__bfde95ba233094b2\Common.dll:
(Location of symbol related to previous error)
Web服务器正在运行Server 2003的我到C:\ WINDOWS \组装和事实上的通知这样做,有3个版本Common.dll上市。列出的最高版本是3.3.4269.17112
The web server is running Server 2003. I went to c:\windows\assembly and did in fact notice that there were 3 versions of Common.dll listed. The highest version listed was 3.3.4269.17112
我复制版本的DLL:3.3.4273.24368到组件目录。我再重新编译和重新部署我的code(可能是矫枉过正,但哦)。当我打开我的浏览器在一个新的会话,并亲临现场URL再次我仍然得到了同样的信息。
I copied the dll with version: 3.3.4273.24368 into the assembly directory. I then re-compiled and re-deployed my code (probably overkill but oh well). When I opened my browser in a new session and went to the site URL again I still got the same message.
我可以使用Windows资源管理器,并验证更高版本Common.dll现在列出。
I can use windows explorer and verify the higher-versioned Common.dll is now listed as well.
我还能考虑来解决这个问题?我不想改变参考在我的组装指向旧版本。
What more can I look into to resolve this issue? I don't want to change the reference in my assembly to point to the older version.
推荐答案
3的想法为你尝试:
- 确保您所有的DLL是编译的通用的版本相同。
- 检查,你有你的解决方案,而不是文件引用项目引用。
- 使用绑定重定向的在你的web.config
- Make sure that all your dlls are compiled against the same version of Common.
- Check that you have project references in your solution instead of file references.
- Use binding redirections in your web.config
这篇关于错误CS1705:"后者具有更高版本比引用的程序集和QUOT;的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!