Clearing a session
<p>I have a session class where i am saving text box values(application) in a session. However, when the user times out due to inactivity or just goes back to the home page i want to clear all session data.
    I tried to set it in the  homepage but the !IsPostBack keeps firing.</p>

<pre><code>if (!IsPostBack)
{
    JobPositionSystemDAL jps = new JobPositionSystemDAL();
    DataSet ds = jps.GetJobs();

    GridView2.DataSource = ds;
    GridView2.DataBind();
}

if (IsPostBack)
{
    Session.RemoveAll();
}
</code></pre>

<p>Thank you.</p>
