示例#1
0
        private void MainForm_Load(object sender, EventArgs e)
        {
            this.toolStripStatusLabel1.Text = "当前系统时间:" + DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss");
            this.timer1.Interval            = 1000;
            this.timer1.Start();

            this.Hide();
            loginForm    frmlogin = new loginForm();
            DialogResult dg       = frmlogin.ShowDialog();

            if (dg == DialogResult.OK)
            {
                DialogResult dg2 = new checkExamNameForm().ShowDialog();
                if (dg2 == DialogResult.OK)
                {
                    this.Show();
                    toolStripStatusLabel3.Text = "当前考试名称: " + publicModel.examName;
                    personInfo info = new personInfo();
                    info.MdiParent = this;
                    info.Show();
                }
                else
                {
                    this.Close();
                }
            }
            else
            {
                this.Close();
            }
        }
示例#2
0
 private void 个人信息ToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (!IsChildFormExist("personInfo"))
     {
         personInfo info = new personInfo();
         info.MdiParent = this;
         info.Show();
     }
 }