且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

当前上下文中不存在名称“HttpContext”

更新时间:2023-02-16 15:25:24



Hi,
Quote:

当前上下文中不存在名称'HttpContext'

The name 'HttpContext' does not exist in the current context



试试这个:


Try this:

System.Web.HttpContext
//Add System.Web.dll by right clicking to your solution explorer -> Add reference





--Amit



--Amit


添加参考
System.web

到你的 Webapplication 类库


httpContext仅支持UI页面解决方案.....试试.......
httpContext supports only the in UI Page Solution.....Try it.......