private void btnMaPhong_Click(object sender, EventArgs e) { frmPhong p = new frmPhong(); p.ShowDialog(); pctrl1.HienthiComboBox(cmbMaPHong); }
private void btnThemMaPhong_Click(object sender, EventArgs e) { Phong p = null; p.ShowDialog(); pctrl1.HienthiComboBox(cmbMaPhg); }
private void PhieuDangKy_Load(object sender, EventArgs e) { pctrl1.HienthiComboBox(cmbMaPHong); cmbMaPHong.SelectedValue = maphong; pctrl.HienthiDataGridviewComboBoxMaPhong(MaPhong); khctrl.HienthiComboBox(cmbMaKH); ctrl.HienThiPhieuThue(dataGridViewX1, bindingNavigator1); bindingNavigator1.BindingSource.CurrentChanged -= new EventHandler(BindingSource_CurrentChanged); bindingNavigator1.BindingSource.CurrentChanged += new EventHandler(BindingSource_CurrentChanged); ctpnctrl.HienThi(dataGridViewX1, txtMaPhieuThue.Text); if (status == Controll.AddNew) { txtMaPhieuThue.Text = ThamSo.LayPhieuDangKy().ToString(); Allow(true); } else { Allow(false); } }