public Main_Controller(string password, string tolerance, Reading reader, Writing writer, DataGridView show, string log)
 {
     internet         = new Internet(new Execute(Run));
     this.reader      = reader;
     this.writer      = writer;
     this.show        = show;
     this.password    = password;
     this.Tolerance   = Int32.Parse(tolerance);
     logger           = new StreamWriter(log, true);
     logger.AutoFlush = true;
 }
Exemple #2
0
        private void init_database_Click(object sender, EventArgs e)
        {
            confirm_delay.Enabled = type_delay.Enabled = activate.Enabled = true;
            close.Enabled         = db_account.Enabled = db_name.Enabled = false;
            db_password.Enabled   = init_database.Enabled = false;
            Database db = new Database(db_account.Text, db_name.Text, db_password.Text);
            Writing  w  = new Writing();
            Reading  r  = new Reading(db);

            controller      = new Main_Controller(protocol_password.Text, Timestamp_Delay.Text, r, w, show_data, log_location.Text);
            Updater.Enabled = true;
        }