Update query is not updating the data in table in my project
<p>This is my code. It is not updating the data in table. I cant see any error. The code is executing and displays me that "Successfully updated".</p>

<pre><code> protected void btnUpdate_Click(object sender, EventArgs e)
    {
        string val = ddlCountry.SelectedValue;
        Response.Write(val); // just to check that the value is changed or not.

        string val2 = txtName.Text;
        Response.Write(val2);

        if (ddlCity.SelectedValue == "--Select--")
        {

            Response.Redirect("updateProfile.aspx");
            lblCountry.Text = "Select your country";
        }
        else if(ddlYear.SelectedValue=="--Select--")
        {

            Response.Redirect("updateProfile.aspx");
            lblCountry.Text = "Select Appropriate Experience";
        }
        else if (ddlMonth.SelectedValue == "--Select--")
        {

            Response.Redirect("updateProfile.aspx");
            lblCountry.Text = "Select Appropriate Experience";
        }
        else if(ddlIndustry.SelectedValue=="--Select--")
        {

            Response.Redirect("updateProfile.aspx");
            lblCountry.Text = "Select Your Current Industry";
        }
        else if(ddlFunction.SelectedValue=="--Select--")
        {

            Response.Redirect("updateProfile.aspx");
            lblCountry.Text = "Select your functional Area";
        }
        else
        {
            string fName = Convert.ToString(Session["fname"]);
            string updateQuery = "Update RegisterMaster set Name='" + txtName.Text + "',Nationality='" + ddlCountry.SelectedValue + "',CurrentLocation='" + ddlCity.SelectedValue + "',MobNumber='"+txtNumber.Text+"',Experience='"+ddlYear.SelectedValue+" "+ddlMonth.SelectedValue+"',CurrentIndustry='"+ddlIndustry.SelectedValue+"',FunctionalArea='"+ddlFunction.SelectedValue+"',KeySkills='"+txtSkills.Text+"',ResumeTitle='"+txtResTitle.Text+"',Resume='"+resFileUpload.ToString()+"' where Name='"+fName+"'";

           int i = c1.ExecuteMyQuery(updateQuery);
           if (i == 1)
           {
               lblUpdation.Text = "Successfully Updated.";
           }
           else
           {
               lblUpdation.Text = "Try Again";
           }

        }
    }
</code></pre>

<p>And it displays that update was successful but when i check database, it is not updated.
<code>updateProfile.aspx</code> is the same page on which this coding is done. and its in a frameset if that also counts.</p>

<p>implementation of </p>

<pre><code>c1.ExecuteMyQuery(updateQuery);


 public int ExecuteMyQuery(String sql)
        {
            con.Open();
            cmd.Connection = con;
            cmd.CommandText = sql;
            int i = cmd.ExecuteNonQuery();
            con.Close();
            return i;
        }
</code></pre>

<p><img src="http://i.stack.imgur.com/zUKGr.png" alt="This is view profile page">
<img src="http://i.stack.imgur.com/9d7tT.png" alt="This is when I clicked on Update profile">
<img src="http://i.stack.imgur.com/UynaQ.png" alt="This is after i click on update button"></p>

<p>whats this????</p>

<blockquote>
  <p>oops! Your question couldn't be submitted because:</p>
  
  <p>Your post does not have much context to explain the code sections;
  please explain your scenario more clearly.</p>
</blockquote>
