System.IO.FileNotFoundException:无法加载文件或程序集' Microsoft.WindowsAzure.ServiceRuntime,Version = 2.5.0.0

时间:2015-09-03 15:22:41

标签: c# azure

在Azure上我收到以下错误

System.IO.FileNotFoundException:无法加载文件或程序集' Microsoft.WindowsAzure.ServiceRuntime,Version = 2.5.0.0,Culture = neutral,PublicKeyToken = 31bf3856ad364e35'或其中一个依赖项。该系统找不到指定的文件。 文件名:' Microsoft.WindowsAzure.ServiceRuntime,Version = 2.5.0.0,Culture = neutral,PublicKeyToken = 31bf3856ad364e35'    at redacted.Encryption.EncryptionManager.get_storageConectionString()    在redacted..ctor()in<>:第49行

警告:装配绑定日志记录已关闭。 要启用程序集绑定失败日志记录,请将注册表值[HKLM \ Software \ Microsoft \ Fusion!EnableLog](DWORD)设置为1。 注意:程序集绑定失败日志记录会导致一些性能损失。 要关闭此功能,请删除注册表值[HKLM \ Software \ Microsoft \ Fusion!EnableLog]。

1 个答案:

答案 0 :(得分:0)

答案是我更新了azure工具2.7并引用了2.5 dll版本。

1)删除项目中对2.5 dll的引用(如果需要,删除.csproj文件),并添加对2.7 System.WindowsAzure.ServiceRuntime dll的引用。

2)重新部署。

3)利润。