添加命名空间using System.Web.SessionState;

 

其中:System.Web.SessionState.IReadOnlySessionState  为只读会话的接口;System.Web.SessionState.IRequiresSessionState 为可读可写会话的接口 

public class GoodAnswer : IHttpHandler, IRequiresSessionState//接口
{

     if (HttpContext.Current.Session["serverCode"].ToString() == servercode)
           return "1";

}

相关文章:

  • 2022-12-23
  • 2022-01-06
  • 2022-12-23
  • 2022-12-23
  • 2021-12-09
  • 2022-12-23
  • 2021-04-24
  • 2021-06-03
猜你喜欢
  • 2022-02-10
  • 2022-12-23
  • 2022-12-23
  • 2021-09-08
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案