如果没有引入using System.Web.SessionState;空间

和IRequiresSessionState(或者IReadOnlySessionState)接口,

那么会出现session对象未将实例化的错误。