Ejemplo n.º 1
0
 private void btnDangNhap_Click(object sender, EventArgs e)
 {
     obj = nvBus.GetUser(txtUserName.Text, txtPassword.Text);
     //obj = nvDao.GetDataByName(txtUserName.Text, txtPassword.Text);
     if (obj != null)
     {
         frmMain frm = new frmMain();
         frm.nvObj = obj;
         frm.Show();
         Hide();
     }
     else
     {
         XtraMessageBox.Show("Đăng nhập thất bại", "Thông báo!");
         txtPassword.Text = string.Empty;
         txtUserName.Text = string.Empty;
         txtUserName.Focus();
     }
 }