Ejemplo n.º 1
0
        private void button1_Click(object sender, EventArgs e)
        {
            if (textBox1.Text == "陈杰" && textBox2.Text == "123" || textBox1.Text == "何辉" && textBox2.Text == "456")
            {
                FrmStudent f = new FrmStudent();
                f.Show();
                this.Hide();
            }

            else
            {
                MessageBox.Show("账号或密码错误");
            }
        }
Ejemplo n.º 2
0
        private void button1_Click(object sender, EventArgs e)
        {
            string name     = this.textBox1.Text;
            string password = this.textBox2.Text;

            if (name.Equals("swpu") && password.Equals("123456"))
            {
                FrmStudent frm = new FrmStudent();
                frm.Show();
                this.Hide();
            }
            else
            {
                MessageBox.Show("登录失败");
            }
        }
Ejemplo n.º 3
0
        private void Login_Click(object sender, EventArgs e)
        {
            string name     = this.TBname.Text;
            string password = this.TBpwd.Text;

            if (name.Equals("黄老师") && password.Equals("123"))
            {
                FrmStudent frm = new FrmStudent();
                frm.Show();
                this.Hide();
            }
            else
            {
                MessageBox.Show("用户名或密码错误");
            }
        }
Ejemplo n.º 4
0
 private void button1_Click(object sender, EventArgs e)
 {
     if (textBox1.Text == "黄本巍" && textBox2.Text == "123456")
     {
         MessageBox.Show("欢迎登录!", "提示");
         this.Hide();
         FrmStudent frmStudent = new FrmStudent();
         frmStudent.Show();
     }
     if (textBox1.Text == "付昶宇" && textBox2.Text == "123456")
     {
         MessageBox.Show("欢迎登录!", "提示");
         this.Hide();
         FrmStudent frmStudent = new FrmStudent();
         frmStudent.Show();
     }
 }
Ejemplo n.º 5
0
        private void button1_Click(object sender, EventArgs e)
        {
            if
            (textBox1.Text == "王静宜" &&
             textBox2.Text == "123456")
            {
                Console.WriteLine("登录成功!");
            }
            if
            (textBox1.Text == "顾毓" &&
             textBox2.Text == "123456")
            {
                Console.WriteLine("登录成功!");
            }
            FrmStudent h = new FrmStudent();

            h.Show();
        }