Хабр
- 1 ответ
- 0 вопросов
0
Вклад в тег
public static void SQLSendData(string ConnectionString, string CommandString)
{
using (MySqlConnection connection = new MySqlConnection(ConnectionString))
{
try
{
MySqlCommand command = new MySqlCommand(CommandString, connection);
command.Connection = connection;
connection.Open();
rowsAffected = command.ExecuteNonQuery();
}
catch (SqlException e)
{
MessageBox.Show(e.Message);
}
finally
{
connection.Close();
}
}
}
SQLSendData("ConnectionString", "UPDATE blablalbalba");