I get the following error in the production environment
Session state can only be used when enableSessionState is set to true, either in a configuration file or in the Page directive. Please also make sure that System.Web.SessionStateModule or a custom session state module is included in the configuration\system.web\httpModules section in the application configuration.
The following things I have tried as of now
machine.config
and web.config
, both have enableSessionState="true"
enableSessionState="true"
to pages in web.config
<httpmodules>
sectionenableSessionState="true"
in page directiveNote: When I try to debug the code in Dev environment, everything works fine as it should.
Can anyone help me out getting over this issue, I just can't figure out a way out of it.
What does your session state config look like? You probably want to be set up to use inproc session handling.