public QuanLyBanSach123(accountDTO acc) { InitializeComponent(); this.Loginacc = acc; dtgvsearch.DataSource = listSach; LoadSach(); LoadLoaiSach(); AddSachBinding(); admin(); ShowName(); testbill(); hienthihoadon(); }
private void button1_Click(object sender, EventArgs e) { string username = txtusername.Text; string passWord = txtpassword.Text; if (Login(username, passWord)) { accountDTO loginacc = accountDAO.Instance.GetTen(username); QuanLyBanSach123 f = new QuanLyBanSach123(loginacc); this.Hide(); f.ShowDialog(); this.Show(); } else { MessageBox.Show("Tài khoản hoặc mật khẩu không đúng!!!", "Thông Báo", MessageBoxButtons.OK); } }