愤斗的程序猿丷
Keep on going never give up.

如果项目中不同第三方类库分别使用了不同版本的Newtonsoft.Json,可以在配置文件中添加以下节点,将0.0.0.0-9.0.0.0此区间的Newtonsoft.Json使用全部强制指向到项目中使用的版本。

<runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed" />
        <bindingRedirect oldVersion="0.0.0.0-9.0.0.0" newVersion="7.0.0.0" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>

 

posted on 2020-02-19 16:33  愤斗的程序猿丷  阅读(466)  评论(0编辑  收藏  举报