引入System.Net.Http后,运行页面还是报错
using System.Net.Http;
chatGPT解释需要安装Microsoft.AspNet.WebApi.Client包,IIS安装的包文件存储在bin目录下,安装包后bin目录多出了一些列文件
运行页面后还是报错
需要在web.config配置文件中加入程序集引用
增加System.Net.Http程序集
<system.web><compilation debug="true" batch="false" targetFramework="4.5"><assemblies><add assembly="System.Net.Http" /></assemblies></compilation><httpRuntime maxRequestLength="2147483647" executionTimeout="120000" /></system.web>