You Have Try to do this code....
protected void BTNSAVE_Click(object sender, EventArgs e)
{
SqlConnection con = new SqlConnection("Data Source=NSYS1\\SQLEXPRESS;Initial Catalog=agfl;connect timeout=30;Integrated Security=True");
con.open();
string qry="Insert Into stf(sno,rdate,acno,name,vno,amt,edate,chno)
Values(@sno,@rdate,@acno,@name,@vno,@amt,@edate,@chno)";
SqlCommand mycom = new SqlCommand(con,qry);
mycom.Parameters.AddWithValue("@sno",TextBox1.Text);
mycom.Parameters.AddWithValue("@rdate",TextBox6.Text);
mycom.Parameters.AddWithValue("@acno",TextBox2.Text);
mycom.Parameters.AddWithValue("@name",TextBox7.Text);
mycom.Parameters.AddWithValue("@vno",TextBox4.Text);
mycom.Parameters.AddWithValue("@amt",TextBox8.Text);
mycom.Parameters.AddWithValue("@edate",TextBox5.Text);
mycom.Parameters.AddWithValue("@chno",TextBox9.Text);
mycom.ExecuteNonQuery();
con.Close();
}
Friend Your Button Click Event Is Remaining..........
you directly generate this code..
protected void BTNSAVE(object sender, EventArgs e)
it's not possible so just check your code and then run your application .
And also check Your client side code where BTNSAVE_click event is also remaining on Button Control....
In Above Code You Have remove extra comma after
TextBox9.Text + "',) so just remove
comma and run your application