我試圖讓我的在asp.net MVC應用程序的用戶的一些信息與Visual Studio 2015年System.Web.HttpContext.Current不存在
當我嘗試從請求獲取信息與
System.Web.HttpContext.Current req = new System.Web.HttpContext.Current();
我得到一個錯誤Error CS0426 The type name 'Current' does not exist in the type 'HttpContext'
任何人都知道如何解決這一問題?
'Current'是一個屬性,而不是一個方法。 –
...一個靜態屬性,而不是一個類型。 –
'var req = new System.Web.HttpContext.Current;' – Igor