ashx中使用HttpContext.Current.Session ,出现未将对象引用设置到实例

 

1.using System.Web.SessionState;

2.public class {ClassName}: IHttpHandler, IReadOnlySessionState{…}

“IReadOnlySessionState”,指定目标HTTP处理程序只需要具有对话访问状态值的读访问权限。


你可能感兴趣的:(ashx中使用HttpContext.Current.Session ,出现未将对象引用设置到实例)