首页 新闻 会员 周边

在IHttpModule中Init方法注册EndRequest 在其他Page页面使用Session 异常!

0
悬赏园豆:5 [已关闭问题] 关闭于 2015-09-01 15:40

“System.Web.HttpException”类型的异常在 System.Web.dll 中发生,但未在用户代码中进行处理

其他信息: 只有在配置文件或 Page 指令中将 enableSessionState 设置为 true 时,才能使用会话状态。还请确保在应用程序配置的 <configuration>\<system.web>\<httpModules> 节中包括 System.Web.SessionStateMod 或自定义会话状态模块。

问题补充:

<?xml version="1.0" encoding="utf-8"?>
<!--
有关如何配置 ASP.NET 应用程序的详细信息,请访问
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<system.web>
<compilation debug="true" targetFramework="4.5" />

<httpRuntime targetFramework="4.5" />
</system.web>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true">
<add name="session" type="WebApplication1.SessionPublic,WebApplication1"/>
</modules>
</system.webServer>
</configuration>

mycing的主页 mycing | 初学一级 | 园豆:197
提问于:2015-08-30 20:06
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册