首页 新闻 会员 周边

centos 发布weiApi

0
[已关闭问题] 关闭于 2016-11-23 14:19

System.Web.Compilation.CompilationException
CS0012: The type `System.Net.Http.HttpMethod' is defined in an assembly that is not referenced. Consider adding a reference to assembly `System.Net.Http, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

Description: Error compiling a resource required to service this request. Review your source file and modify it to fix this error.

Details: CS0012: The type `System.Net.Http.HttpMethod' is defined in an assembly that is not referenced. Consider adding a reference to assembly `System.Net.Http, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

Error origin: Compiler

Error source file: ~/Areas/HelpPage/Views/Help/DisplayTemplates/ApiGroup.cshtml

孤_的主页 孤_ | 初学一级 | 园豆:13
提问于:2016-05-03 10:28
< >
分享
所有回答(2)
0

 你解决了么,我也遇到了

Hudan | 园豆:202 (菜鸟二级) | 2018-05-10 15:23
0

其实很简单,只需要在web.config配置文件中,添加程序集的引用即可!具体入下:
<system.web>
<compilation debug="true" targetFramework="4.5.1" >
<assemblies>
<add assembly="System.Net.Http, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
</assemblies>
</compilation>
</system.web>

李朝强 | 园豆:204 (菜鸟二级) | 2018-11-12 19:48
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册