No backend database, only dynamically created table bound to GridView
<p>I am need a solution like this: no backend database, no Xml, no Excel, only when user gives information display in GridData. Only creating dynamically in the <code>.aspx.cs</code> table and column ...</p>

<p>Eg:--</p>

<pre><code>Name |-Text box-| Button
</code></pre>

<p>Gridview</p>

<p>When user visited page ..like above Name with TextBox and Submit Button  .</p>

<p>When user enters a name in the TextBox and clicks on submit I want to add that name to the grid, but here I want not only presented data... also previous enter data display in Gridview.</p>

<p>eg2:-</p>

<pre><code>sairam  submit---&gt;click
pamidi  submit--&gt;clcick 
</code></pre>

<p>I want display how many values user enter that many i want to display in gridview ,like this</p>

<pre><code>sairam
pamidi
some....
more...
values..
</code></pre>

<p>up-to when user perform close of browser .</p>

<p><code>info.aspx</code>:</p>

<pre><code>&lt;form id="form1" runat="server"&gt;
    &lt;div&gt;
    &lt;asp:Label ID="Label1" runat="server" Text="Enter Name"&gt;&lt;/asp:Label&gt;
      &lt;asp:TextBox  ID="TextBox1" runat="server"&gt;&lt;/asp:TextBox&gt;
      &lt;asp:Button ID="btnSumbit"  runat="server" Text="Submit" 
            onclick="btnSumbit_Click" /&gt;
      &lt;asp:GridView ID="aspGrid1" runat="server" AutoGenerateColumns="false"  &gt;

       &lt;Columns&gt;
       &lt;asp:TemplateField&gt;
       &lt;ItemTemplate&gt;
       &lt;%#Eval("Name") %&gt;
       &lt;/ItemTemplate&gt;
       &lt;/asp:TemplateField&gt;
       &lt;/Columns&gt;
      &lt;/asp:GridView&gt;
&lt;/div&gt;
&lt;/form&gt;
</code></pre>

<p><code>info.aspx.cs</code>:</p>

<pre><code>public partial class Default6 : System.Web.UI.Page
{
    DataTable dt = new DataTable();
    protected void Page_Load(object sender, EventArgs e)
    {
        dt.Columns.Add("Name", typeof(string));
        dt.Rows.Add(TextBox1.Text);
        ViewState["DataTable"] = dt;

    }
    protected void btnSumbit_Click(object sender, EventArgs e)
    {
        if (TextBox1.Text == " ")
        {
            return;
        }
        else if (TextBox1.Text != string.Empty)
        {
            aspGrid1.DataSource = (DataTable)ViewState["DataTable"];
            aspGrid1.DataBind();
        }
    }
}
</code></pre>
