title: Application State under .Net 4.0 and IIS7 is not working
body: <p>I have been developing an ASP.Net 4.0 web application, and I have used the HttpApplicationState class with its Contents property to set some variables in the Application_Start event of the Global_asax file.</p>
  
  <p>While the application runs as expected on my development machine, when it is deployed on the production server running IIS7 the values returned for the application state variables are null. I have tried various code techniques, like using the HttpContext,Runtime.Cache, the Application["key"], and the Application.Contents.Add["key",Value], all with no success. I am wondering now whether there should be a special configuration on IIS7 on this; researching the topic I see that people say that the application pool in which the application is executed must be served by only a single worker process; I am no IIS7 expert, but selecting the application pool, and viewing its advanced properties, I can see that the pool is configured to have a maximum of 1 worker process, so I believe this should cover it. I have spent a good 2 days on this, so if anyone has any knowledge of this issue, please help!</p>
  
  <p>thanks</p>
  
  <p>chris</p>