Text not getting inserted into table, but only auto incrementing other column
<p>I have multiple <code>textboxes</code> that goes into a table called <code>dbo.skills</code></p>

<pre><code>dbo.Skills SkillID (PK- AutoIncrement) | SkillName 
</code></pre>

<p>So when I used this method, the name is not getting stored but only SkillID is getting auto-incremented.  <strong>Here is my .cs code</strong></p>

<pre><code> public void InsertSkillInfo()
    {


        String KKStech = @"Data Source=USER-PC\SQLEXPRESS;Initial Catalog=KKSTech;Integrated Security=True";
        SqlConnection conn = new SqlConnection(KKStech);

        try
        {

            for (int i = 1; i &lt;= 4; i++)
            {
                conn.Open();

                //string skill = (TextBox)((Page.FindControl("TextBox" + i.ToString()))).Text;

                var skill = "";
                var control = Page.FindControl("TextBox" + i.ToString()) as TextBox;
                if (control != null)
                {
                    skill = control.Text;
                }
                const string sqlStatement = "INSERT INTO Skills (SkillName) VALUES (@SkillName)";
                SqlCommand cmd = new SqlCommand(sqlStatement, conn);
                cmd.CommandType = CommandType.Text;
                cmd.Parameters.AddWithValue("@SkillName", skill);
                cmd.ExecuteNonQuery();
                conn.Close();
            }
        }

        catch (System.Data.SqlClient.SqlException ex)
        {
            string msg = "Insert Error:";
            msg += ex.Message;
            throw new Exception(msg);
        }
</code></pre>

<p>After entering values in textboxes, table looks like this-</p>

<pre><code>Dbo.Skills
SkillID | SkillName
1       | 
2       | 
3       | 
4       | 
</code></pre>

<p>ASPX code:</p>

<pre><code> &lt;asp:Label ID="Label1" class="caption" runat="server" Text="Skill Name"&gt;&lt;/asp:Label&gt;
    &lt;asp:TextBox ID="TextBox1" class="box" runat="server"&gt;&lt;/asp:TextBox&gt; &lt;br /&gt; &lt;br /&gt;

    &lt;asp:Label ID="Label2" class="caption" runat="server" Text="Skill Name"&gt;&lt;/asp:Label&gt;
    &lt;asp:TextBox ID="TextBox2" class="box" runat="server"&gt;&lt;/asp:TextBox&gt; &lt;br /&gt; &lt;br /&gt;

    &lt;asp:Label ID="Label3" class="caption" runat="server" Text="Skill Name"&gt;&lt;/asp:Label&gt;
    &lt;asp:TextBox ID="TextBox3" class="box" runat="server"&gt;&lt;/asp:TextBox&gt; &lt;br /&gt; &lt;br /&gt;

    &lt;asp:Button ID="Button1" class="box" runat="server" Text="Insert" 
        onclick="Button1_Click" /&gt; &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;
</code></pre>
