private void btnDangNhap_Click(object sender, EventArgs e) { if (txtTaiKhoan.Text == "") { XtraMessageBox.Show("Chưa nhập tên đăng nhập", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Error); txtTaiKhoan.Focus(); } if (txtMatKhau.Text == "") { XtraMessageBox.Show("Chưa nhập mật khẩu", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Error); txtMatKhau.Focus(); } if (NGUOIDUNG_BUS.DangNhap(txtTaiKhoan.Text, txtMatKhau.Text)) { string tenDangNhap = txtTaiKhoan.Text; frmManHinhChinh frm = new frmManHinhChinh(tenDangNhap); frm.Show(); this.Hide(); } else { MessageBox.Show("Sai tài khoản hoặc mật khẩu"); } }
private void frmThongTinNguoiDung_Load(object sender, EventArgs e) { lbChucVu.Text = NGUOIDUNG_BUS.LayQuyen(CurrentUser.Code); lbTenNgDung.Text = NGUOIDUNG_BUS.LayTenNguoiDung(CurrentUser.Code); lbTenTaiKhoan.Text = NGUOIDUNG_BUS.LayTenDangNhap(CurrentUser.Code); }
private void load_DSNguoiDung() { bindingSourceNguoiDung.DataSource = NGUOIDUNG_BUS.LayTatCaNguoiDung(); }
private void frmManHinhChinh_Load(object sender, EventArgs e) { staticNamHoc.Caption = "Năm học: " + NAMHOC_BUS.LayNamHocHienTai().TENNAMHOC.ToString(); staticNguoiDung.Caption = "Người dùng: " + NGUOIDUNG_BUS.LayTenNguoiDung(username).ToString(); }
private void btnReset_Click(object sender, EventArgs e) { string maND = dgvNguoiDung.GetFocusedRowCellDisplayText(col_maNguoiDung); NGUOIDUNG_BUS.ResetMK(maND); }