Posted on: 9/24/2014 7:23:51 PM | Views : 364

hi,
when I  try to update row its not updating anything  in the row
protected void GridView3_RowUpdating(object sender, GridViewUpdateEventArgs e) { SqlConnection con = new SqlConnection(Connection); GridViewRow row = (GridViewRow)GridView3.Rows[e.RowIndex]; string item = ((TextBox)row.FindControl("txtItem")).Text ; string dsc = ((TextBox)row.FindControl("txtDesc")).Text; string quant = ((TextBox)row.FindControl("txtQuantity")).Text; string price = ((TextBox)row.FindControl("txtPrice")).Text; string str = "update testitem set Description=@Description,Quantity=@Quantity,Price=@Price where PID=@PID and Item=@Item"; SqlCommand cmd = new SqlCommand(str, con); cmd.Parameters.Add("@Item", SqlDbType.VarChar).Value = item; ...

Go to the complete details ...