public Controller(FrmView FrmSurface, string Db)
 {
     frmSurface = FrmSurface;
     if (Db == "sqlite")
     {
         theSQLiteconnector = new SQLiteConn("Data Source=converted.db;", "converted.db");
         //theSQLiteconnector = new SQLiteConn("Data Source=ems.sqlite; Version=3;", "ems.");
         SQLiteConnection Conn = theSQLiteconnector.getConnector();
         theSQLiteQueryHandler = new SQLiteQueryHandler(ref Conn, theSQLiteconnector, this);
     }
     else
     {
         //theCalculator = new Calculator();
         theSQLconnector = new SQLconn(CreateConnStr("localhost", "root", "", "ems_db", "Convert Zero Datetime = True")); // server, benutzer, passwort und Datenbankbezeichnung eingeben
         MySqlConnection conn = theSQLconnector.getConnector();
         theQueryHandler = new QueryHandler(ref conn, theSQLconnector, this);
     }
 }
Esempio n. 2
0
 public Controller(FrmView FrmSurface, string Db)
 {
     frmSurface = FrmSurface;
     if (Db == "sqlite")
     {
         theSQLiteconnector = new SQLiteConn("Data Source=converted.db;", "converted.db");
         //theSQLiteconnector = new SQLiteConn("Data Source=ems.sqlite; Version=3;", "ems.");
         SQLiteConnection Conn = theSQLiteconnector.getConnector();
         theSQLiteQueryHandler = new SQLiteQueryHandler(ref Conn, theSQLiteconnector, this);
     }
     else
     {
         //theCalculator = new Calculator();
         theSQLconnector = new SQLconn(CreateConnStr("localhost", "root", "", "ems_db", "Convert Zero Datetime = True")); // server, benutzer, passwort und Datenbankbezeichnung eingeben
         MySqlConnection conn = theSQLconnector.getConnector();
         theQueryHandler = new QueryHandler(ref conn, theSQLconnector, this);
     }
 }