Exemple #1
0
        private void btn_thoat_Click(object sender, EventArgs e)
        {
            ChucNang cn = new ChucNang();

            cn.Show();
            this.Hide();
        }
Exemple #2
0
        private void button1_Click(object sender, EventArgs e)
        {
            conn = new SqlConnection(str);
            conn.Open();
            SqlCommand cmd = new SqlCommand("select count(*) from Quanly where taikhoan ='" + txt_tk.Text + "'and matkhau='" + txt_mk.Text + "'", conn);
            int        x   = Convert.ToInt32(cmd.ExecuteScalar().ToString());

            conn.Close();
            if (x == 1)
            {
                MessageBox.Show("Đăng Nhập Thành Công");
                ChucNang cn = new ChucNang();
                cn.Show();
            }
            else
            {
                MessageBox.Show("Đăng Nhập Không Thành Công" +
                                "Mời Nhập Lại");
            }
            this.Hide();
        }
Exemple #3
0
        private void button4_Click_1(object sender, EventArgs e)
        {
            ChucNang cn = new ChucNang();

            cn.Show();
        }