Advertisement
Guest User

Untitled

a guest
May 24th, 2015
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.59 KB | None | 0 0
  1. string a1 = dataGridView4.Rows[0].Cells[0].Value.ToString();
  2.                 string a2 = dataGridView4.Rows[0].Cells[1].Value.ToString();
  3.                 string a3 = dataGridView4.Rows[0].Cells[2].Value.ToString();
  4.                 string a4 = dataGridView4.Rows[0].Cells[3].Value.ToString();
  5.  
  6.  
  7.  
  8.                 MySqlCommand command = con.CreateCommand();
  9.                 command.CommandText = "update druzyny  set ID_t='" + a2 + "',nazwa_d='" + a3 + "',punkty_d='" + a4 + "' where id_d='" + a1 + "';";
  10.                 con.Open(); //open the connection
  11.                 command.ExecuteNonQuery();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement