Вот так:
using MySql.Data.MySqlClient;
MySqlConnection myConnection = new MySqlConnection();
myConnection.ConnectionString = myConnectionString;
myConnection.Open();
//execute queries, etc
myConnection.Close();
Где myConnectionString
имеет такой формат:
"Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;"