Must declare the scalar variable hatası , aspx-sql
Must declare the scalar variable "@uTelNo" hatası alıyorum. Sorun tam olarak nerede anlayamadım, yardımcı olabilir misiniz? Kodlar aşağıdaki gibi.
protected void Button1_Click(object sender, EventArgs e)
{
comm = new SqlConnection(connection);
SqlCommand command = new SqlCommand();
command.CommandType = CommandType.Text;
command.Connection = comm;
command.CommandText = "update [uyeler] set uTelNo=@uTelNo,uEmail=@uEmail,uAdres=@uAdres where uTcNo=@uTcNo";
comm.Open();
command.ExecuteNonQuery();
command.Parameters.AddWithValue("@uTelNo", TextBox4.Text);
command.Parameters.AddWithValue("@uEmail", TextBox5.Text);
command.Parameters.AddWithValue("@uAdres", TextBox6.Text);
command.Parameters.AddWithValue("@uSifre", TextBox7.Text);
command.Parameters.AddWithValue("@uTcNo",TextBox8.Text);
comm.Close();
}