コード例 #1
0
ファイル: MainForm.cs プロジェクト: EvgeniiLovesc/ProfTestWin
        public MainForm()
        {
            InitializeComponent();

            tabControl.Hide();
            this.BackColor = ColorTranslator.FromHtml("#C8C9D0");
            objDB          = new DataDB();
            // Заполним DataGrid
            objDB.dgvTests         = this.dataGridTests;
            objDB.dgvUsers         = this.dataGridUsers;
            objDB.dgvRules         = this.dataGridRules;
            objDB.dgvAdmins        = this.dataGridAdmins;
            objDB.dgvResults       = this.dataGridResults;
            objDB.statusConnection = this.lblStatusConnection;
            objDB.serverStatus     = this.lblServerStatus;
            objDB.pbStatus         = this.pbStatusConnection;
            objDB.FillTests();

            //Окно авторизации
            AuthWindow aw = new AuthWindow(objDB.status);

            aw.Show();
            aw.BringToFront();
            aw.TopMost = true;
        }
コード例 #2
0
        public Main()
        {
            //Окно авторизации
            //AuthWindow aw = new AuthWindow();
            //aw.Show();

            // Здесь будем проверять авторизацию

            InitializeComponent();
            this.BackColor = ColorTranslator.FromHtml("#C8C9D0");
            objDB          = new DataDB();
            // Заполним DataGrid
            objDB.dgvTests         = this.dataGridTests;
            objDB.dgvUsers         = this.dataGridUsers;
            objDB.dgvRules         = this.dataGridRules;
            objDB.dgvAdmins        = this.dataGridAdmins;
            objDB.dgvResults       = this.dataGridResults;
            objDB.statusConnection = this.lblStatusConnection;
            objDB.serverStatus     = this.lblServerStatus;
            objDB.pbStatus         = this.pbStatusConnection;
            objDB.FillTests();
        }