Simple post of info from one c# asp.net page to the next issue
<p>I am not using MVC but forms authentication.  I am having trouble getting variable to store when the submit button is pressed.  I have spend 2 days researching how to do this.  At this point I am just trying to get the username to post on the next page. I truly thought I understood the way viewstate worked after doing this for a year. </p>

<p>Code:</p>

<pre><code>protected void Page_Load(object sender, EventArgs e)
    {

        if (IsPostBack) {
            string username = Page.Session["username"].ToString();
            Response.Write(username);
        }

    }

    protected void btnSubmit_Click(object sender, EventArgs e)
    {
        Page.Session["username"] = txtUsername.Text;
    }
</code></pre>
