static schema.database createNewConnection() { MySql.Data.MySqlClient.MySqlConnection conn = new MySql.Data.MySqlClient.MySqlConnection("Server=localhost;Database=ecurie;Uid=root;Pwd=496712;"); conn.Open(); schema.database db = new database(conn); db.xconnection = conn; return db; }
static schema.database createDatabase() { if(db!=null){ db.Dispose(); } db=new database(conn); db.xconnection = conn; schema.database.db = db; return db; }