private void LoadtatCa() { lUpTenPhong.Properties.DataSource = pBUS.LoadPhong(); lUpTenPhong.Properties.DisplayMember = "TenPhong"; lUpTenPhong.Properties.ValueMember = "MaPhong"; lUPCa.Properties.DataSource = ca.LoadCa(); lUPCa.Properties.DisplayMember = "TenCa"; lUPCa.Properties.ValueMember = "MaCa"; lUPtenPhim.Properties.DataSource = phim.LoadPhim(); lUPtenPhim.Properties.DisplayMember = "TenPhim"; lUPtenPhim.Properties.ValueMember = "MaPhim"; gcLichCHieu.DataSource = lich.LoadLich(); LueTenPhim.DataSource = phim.LoadPhim(); LueTenPhog.DataSource = pBUS.LoadPhong(); LueMaCa.DataSource = ca.LoadCa(); dtpGioBatDau.Format = DateTimePickerFormat.Custom; dtpGioBatDau.CustomFormat = "HH:mm"; dtpGioBatDau.ShowUpDown = true; dtpGioKetThuc.Format = DateTimePickerFormat.Custom; dtpGioKetThuc.CustomFormat = "HH:mm"; dtpGioKetThuc.ShowUpDown = true; }
private void FormPhong_Load(object sender, EventArgs e) { button2.Enabled = false; button3.Enabled = false; gcPhong.DataSource = pBUS.LoadPhong(); lUpLoaiPhong.Properties.DataSource = loaiphong.LoadLoaiPhong(); lUpLoaiPhong.Properties.DisplayMember = "TenPhong"; lUpLoaiPhong.Properties.ValueMember = "MaLoai"; repositoryItemLookUpEdit1.DataSource = loaiphong.LoadLoaiPhong(); repositoryItemLookUpEdit1.DisplayMember = "TenPhong"; repositoryItemLookUpEdit1.ValueMember = "MaLoai"; }
private void Loadve() { gcVe.DataSource = ve.LoadVe(); lUpTenPhim.DataSource = phim.LoadPhim(); lUpTenPhong.DataSource = phong.LoadPhong(); lUPTenTV.DataSource = tv.LoadTV(); }
private void LoadDuLieu() { dataTablePhong = PhongBUS.LoadPhong(); dataTablePhong.Columns[0].ColumnName = "Mã phòng"; dataTablePhong.Columns[1].ColumnName = "Khu nhà"; dataTablePhong.Columns[2].ColumnName = "Số phòng"; dataTablePhong.Columns[3].ColumnName = "Số lượng hiện tại"; dataTablePhong.Columns[4].ColumnName = "Số lượng tối đa"; dataTablePhong.Columns[5].ColumnName = "Tình trạng"; dgvPhong.DataSource = dataTablePhong; dataTableSinhVien = PhongBUS.LoadSinhVien(); dataTableSinhVien.Columns[0].ColumnName = "Mã phòng"; dataTableSinhVien.Columns[1].ColumnName = "MSSV"; dataTableSinhVien.Columns[2].ColumnName = "Họ tên"; dgvSinhVien.DataSource = dataTableSinhVien; dgvSinhVien.Columns[3].Visible = false; TimKiem(); }
void refresh() { dtPhong = PhongBUS.LoadPhong(); for (int i = 0; i < dtPhong.Rows.Count; ++i) { string id = (dtPhong.Rows[i]["IDPhong"].ToString()); lstSource.Add(id); lstDes.Add(id); } cboDes.DataSource = lstSource; cboSource.DataSource = lstDes; dgvDes.DataSource = dtDes; dgvSource.DataSource = dtSource; btnQua.Enabled = true; btnLai.Enabled = true; if (list.Count > 0) { list.Clear(); } }