in Web.config Locate the <sessionState> section, and set the mode value to ON .
Exception Details: System.Web.HttpException: Session state can only be used when enableSessionState is set to true, either in a configuration file or in the Page directive。 try: enable sessionState in web.config. enable sessionState in sub page.load enableSessionState=true
1、EnableSessionState默认的是不需要再web.config中设置的。我没有modify这个文件过
2、上面一共有4个StackTrace的信息,大家应该看最后一个,而不是最上面的一个。
3、上述代码是IL之后的,不是我写的这个样子。
4、不知道是不是late-bound的问题?
Locate the <sessionState> section, and set the mode value to ON .
try:
enable sessionState in web.config.
enable sessionState in sub page.load
enableSessionState=true
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="1"/>
核对一下,看你的有哪些区别.
很有用的.HttpException (0x80004005).我查过了好像没有.继续关注.
如果是部署到子目录必须将该子目录设为Application才能正常地使用Session和进程Session状态管理。
ms的人说,需要memory dump,然后debug