Could not load file or assembly 'System.Private.ServiceModel, Version=4.1.2.4, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'


.net core  引用wcf 在發布的時候報錯提示:Could not load file or assembly 'System.Private.ServiceModel, Version=4.1.2.4, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

解決辦法將 wcf 的引用包版本升級到4.5.0以上就可以了

<PackageReference Include="System.ServiceModel.Duplex" Version="4.5.0" />
<PackageReference Include="System.ServiceModel.Http" Version="4.5.0" />
<PackageReference Include="System.ServiceModel.NetTcp" Version="4.5.0" />
<PackageReference Include="System.ServiceModel.Security" Version="4.5.0" />

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM