Ejemplo n.º 1
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            fManager f = new fManager();

            this.Hide();
            f.ShowDialog();
            this.Show();
        }
Ejemplo n.º 2
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            string   username = txbUserName.Text;
            string   pass     = txbPassword.Text;
            fManager f        = new fManager();

            this.Hide();
            f.ShowDialog();
            this.Show();
        }
Ejemplo n.º 3
0
        public void login(string id, string pass)
        {
            fManager f = new fManager();

            if (id == "ADMIN" && pass == "1234")
            {
                f.ShowDialog();
            }
            else
            {
                MessageBox.Show("Mật khẩu hoặc tên đăng nhập sai. Mời nhập lại");
            }
        }
Ejemplo n.º 4
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            string username = txbUserName.Text;
            string pass     = txbPassword.Text;
            //string query = "SELECT * FROM dbo.TAIKHOAN WHERE UNAME = '" + username + "' and PASS = '******'";
            //DataProvider provider = new DataProvider();
            //DataTable da = provider.Execute(query);
            //login.kiemtra(username, pass);
            fManager f = new fManager();

            this.Hide();
            f.ShowDialog();
            this.Show();
        }
Ejemplo n.º 5
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            string username = txbUserName.Text;
            string pass     = txbPassword.Text;
            //string query = "SELECT * FROM dbo.TAIKHOAN WHERE UNAME = '" + username + "' and PASS = '******'";
            //DataProvider provider = new DataProvider();
            //DataTable da = provider.Execute(query);
            //login.kiemtra(username, pass);
            loginDAO login = new loginDAO();

            if (login.Login(username, pass) == true)
            {
                fManager f = new fManager();
                this.Hide();
                f.ShowDialog();
                this.Show();
            }
            else
            {
                MessageBox.Show("Tên đăng nhập hoặc mật khẩu không đúng");
            }
        }