首先,这不仅仅是重复的问题。以下问题的答案都对我没有用。
http://goo.gl/tS40cn
http://goo.gl/pH6v2T
<package id="Newtonsoft.Json" version="7.0.1" targetFramework="net45" />
Web.config 文件包含以下代码:
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.5.0.0" newVersion="4.5.0.0" />
</dependentAssembly>
来自 Newtonsoft.Json
的参考属性
- 使用
Update-Package –reinstall Newtonsoft.Json
重新安装软件包 - 从
Web.config
中删除Newtonsoft.Json
的dependentAssembly
配置 - 更改
dependentAssembly
中的newVersion
为6.0.0.0
和7.0.0.0
。但这样会导致新错误。 - 也尝试过
Get-Project -All | Add-BindingRedirect
,它将Newtonsoft.Json
的newVersion
更改为4.5.0.0
。但问题仍未解决。