예제 #1
0
        private void Tai_Thong_Tin_Tinh_Trang_DG()
        {
            TinhTrangDocGiaBUS tinhTrangDocGia = new TinhTrangDocGiaBUS();
            DataTable          dsTTDG          = tinhTrangDocGia.LayDanhSachTinhTrangDocGia();

            dgvTinhTrangDG.DataSource = dsTTDG;
        }
        private void Tai_Thong_Tin()
        {
            DocGiaBUS docGiaBUS = new DocGiaBUS();

            dsDocGia = docGiaBUS.LayDanhSachDocGia();

            if (LanDauDoDuLieu == 0)
            {
                TinhTrangDocGiaBUS tinhTrangDocGiaBUS = new TinhTrangDocGiaBUS();
                DataTable          dsTTDG             = tinhTrangDocGiaBUS.LayDanhSachTinhTrangDocGia();


                DataGridViewComboBoxColumn dgvComboTinhTrangDocGia = new DataGridViewComboBoxColumn();
                dgvComboTinhTrangDocGia.DataSource       = dsTTDG;
                dgvComboTinhTrangDocGia.DisplayMember    = dsTTDG.Columns[1].ColumnName;
                dgvComboTinhTrangDocGia.ValueMember      = dsTTDG.Columns[0].ColumnName;
                dgvComboTinhTrangDocGia.DataPropertyName = "TTDG";
                dgvComboTinhTrangDocGia.HeaderText       = "Tình Trạng";
                dgvComboTinhTrangDocGia.Width            = 50;

                dgvDanhSachDocGia.Columns.Add(dgvComboTinhTrangDocGia);

                LanDauDoDuLieu++;
            }
            dgvDanhSachDocGia.DataSource = dsDocGia;
        }