title: Input textbox value not updating database table
body: <p>I have created a asp.net webform and I am creating an update profile page. I am testing the connection to the DB by giving a specific user to pull from the user table. The user data does pop up in the  textbox but when I change the text and click the save button the data is not updated. All SQL Queries are stored procedures.</p>
  <p>C# Code:</p>
  <pre><code>    protected void EditProfileBtn_Clicked(object obj, EventArgs args)
      {
          SqlConnection con = new SqlConnection(Connection_string_Is_Here);
  
          if (con.State == ConnectionState.Closed)
          {
              con.Open();
              SqlCommand sqlCommand = new SqlCommand(&quot;EditProfile_sp&quot;, con);
              sqlCommand.CommandType = CommandType.StoredProcedure;
              sqlCommand.Parameters.AddWithValue(&quot;UserID&quot;, userID);
              sqlCommand.Parameters.AddWithValue(&quot;FirstName&quot;, FirstNametbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;LastName&quot;, LastNametbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;Country&quot;, Countrytbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;State&quot;, Statetbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;City&quot;, Citytbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;Email&quot;, Emailtbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;Phone&quot;, Phonetbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;MyInterest&quot;, MyInteresttbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;MySkills&quot;, MySkillstbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;MyRoles&quot;, MyRolestbx.Value);
              sqlCommand.Parameters.AddWithValue(&quot;MyAvailability&quot;, MyAvailtbx.Value);
              sqlCommand.ExecuteNonQuery();
              con.Close();
              Response.Redirect(&quot;Homepage.aspx&quot;);
              
          }
      }
  </code></pre>
  <p>Stored Procedure:</p>
  <pre class="lang-sql prettyprint-override"><code>ALTER PROCEDURE [dbo].[EditProfile_sp] (
  
      @UserID int, 
      @FirstName varchar(50),
      @LastName varchar(50),
      @Country varchar(50),
      @State varchar(50),
      @City varchar(50),
      @Email varchar(50),
      @MyInterest varchar(50),
      @MySkills varchar(50),
      @MyRoles varchar(50),
      @MyAvailability varchar(50),
      @Phone varchar(20)
  
  )
  
  AS 
  
  BEGIN
  
   UPDATE PESAUser 
  
                SET FirstName = @FirstName, LastName = @LastName,
                Country = @Country, [State] = @State, 
                City = @City, Email = @Email, MyInterest = @MyInterest, MySkills = @MySkills, MyRole = @MyRoles,
                MyAvailability = @MyAvailability, Phone = @Phone 
                WHERE UserID = @UserID
  END
  </code></pre>
  <p>There are no thrown exceptions to this code the issue is that there is no updating to the database table. All spelling issues have been checked.</p>