title: Re-imaged my machine & now web project won't run
body: <p>Since I re-imaged my machine I haven't been able to debug an old web project with out getting an error.</p>
  
  <p>When it hits the line:</p>
  
  <pre><code>Page.ViewStateUserKey = Session.SessionID
  </code></pre>
  
  <p>It throws the error:</p>
  
  <pre><code>An exception of type 'System.Web.HttpException' occurred in    App_Web_902sorzv.dll but was not handled in user code
  
  Additional information: 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 &lt;configuration&gt;\&lt;system.web&gt;\&lt;httpModules&gt; section in the application configuration.
  </code></pre>
  
  <p><strong>Additional Info</strong>  </p>
  
  <ul>
  <li>Originally a 2.0 project that was upgraded to 3.5</li>
  <li>Project still runs fine on VM made from image of the old machine</li>
  <li>Added enableSessionState="true" to the pages property in the web.cofig - enablesessionstate</li>
  <li>Site runs fine as it is in TFS on Windows Server R2</li>
  <li>aspnet.config and applicationhost.config in IISExpress are equivalent on both the new machine and VM</li>
  <li>Web project has been upgraded in Visual Studio over time 2005-2008-2010-2012</li>
  <li>Both new machine and VM are Windows 7 with Visual Studio 2012 (VM also has VS 2008 installed)
  </ul>
  
  <p>What am I missing that will allow me to debug the old application on the new set up?</p>