System.Net.Http.Formatting上的Microsoft.AspNet.WebApi.Client参考

时间:2018-11-22 19:23:25

标签: .net nuget nuget-package

我有一个.net standard 2.0库,正在使用Microsoft.AspNet.WebApi.Client版本5.2.6,其中引用了System.Net.Http.Formatting版本5.2.6。

然后从.net 4.6.1开始,我引用了这个.net standard 2.0库,但遇到运行时异常

System.IO.FileLoadException: 'Could not load file or assembly 'System.Net.Http.Formatting, Version=5.2.6.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)'

为什么System.Net.Http.Formatting的版本是5.2.6?据我所知,目前的最大版本是5.2.3。在.net 4.6.1项目的配置文件中,它已添加为5.2.3版本。

我该如何解决?

0 个答案:

没有答案