title: Where I should declare a session variable in asp.net
body: <p>I am building a Asp.net Application. I need to save a HashTable in a session.</p>
  
  <p>At page load i am writing</p>
  
  <pre><code> protected void Page_Load(object sender, EventArgs e)
  {
      if (!Page.IsPostBack)
      {
         Session["AttemptCount"]=new Hashtable(); //Because of this line.
      }   
  }
  </code></pre>
  
  <p>Here problem is, when a user refresh the page, session["AttemptCount"] also get refreshed.
  I want to know where should I declare </p>
  
  <pre><code>Session["AttemptCount"]=new Hashtable();
  </code></pre>
  
  <p>So that my seesion do not get refeshed.</p>
  
  <p><strong>EDIT</strong> In Global.asax, this session will get started, as soon as user opens the website. I want to creat this session only if user go to a particular page. i.e Login.aspx</p>