【发布时间】:2014-04-16 21:28:00
【问题描述】:
平台:Windows 7(64 位) 视觉工作室 2012
我最近安装了 azure SDK 2.2,并让我的解决方案与新的参考一起运行。但是,如果我使用以前版本的解决方案(带有旧参考和 SDK 版本 - 2.0),我会收到此运行时异常:
无法加载文件或程序集“Microsoft.WindowsAzure.Storage, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35”或其依赖项之一。找到的程序集的清单定义与程序集引用不匹配。 (HRESULT 异常:0x80131040)
我从以前的升级中得到了一些提示,并且了解到如果 Visual Studio 抓取的版本不应该是最新版本,您可能需要覆盖它们,因此我在 Web.config 中添加了以下几行:
<dependentAssembly>
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.2.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.WindowsAzure.ServiceRuntime" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.2.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.WindowsAzure.Configuration" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.2.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
我希望这会引导视觉工作室获取适当的版本,但它仍然失败。
任何帮助将不胜感激。
【问题讨论】:
标签: c# .net visual-studio-2012 azure azure-storage