public frmTK_HoatDong() { hpBUS = new HocPhanBUS(); svBUS = new SinhVienBUS(); ctxhBUS = new CTXHBUS(); dsCTXHBUS = new DSSV_CTXHBUS(); rlBUS = new RenLuyenBUS(); dsRLBUS = new DSSV_RLBUS(); vpBUS = new ViPhamBUS(); ktButton = frmMain.ktButtonClick; InitializeComponent(); kiemTra(); if (frmMain.user.LoaiUser == "SinhVien") { this.txtNhapMSSV.Text = frmMain.user.Ma; this.txtNhapMSSV.Enabled = false; TimThongTin(); } else { this.txtNhapMSSV.AutoCompleteMode = AutoCompleteMode.Suggest; this.txtNhapMSSV.AutoCompleteSource = AutoCompleteSource.CustomSource; var lstMSSV = svBUS.getMSSV(); AutoCompleteStringCollection AutoComp = new AutoCompleteStringCollection(); foreach (var sv in lstMSSV) { AutoComp.Add(sv); } this.txtNhapMSSV.AutoCompleteCustomSource = AutoComp; } }
public frmQLDiemThi() { dtBUS = new DIemThiBUS(); hpBUS = new HocPhanBUS(); svBUS = new SinhVienBUS(); InitializeComponent(); LoadData(); }
public frmTimKiem() { ktButton = frmMain.ktButtonClick; svBUS = new SinhVienBUS(); hpBUS = new HocPhanBUS(); InitializeComponent(); kiemTra(); LoadData(); }
// Report Thong Ke HocPhi, CTXH, ViPham public frmReport(string maSV, string hoTen, string maLop, string tong, int ktra) { InitializeComponent(); if (ktra == 12) { HocPhanBUS hpBUS = new HocPhanBUS(); ReportDataSource reportDataSource = new ReportDataSource(); reportDataSource.Name = "dsNoHocPhi_By_MSSV"; reportDataSource.Value = hpBUS.getHPByMaSV(maSV); reportViewer1.LocalReport.DataSources.Add(reportDataSource); this.reportViewer1.LocalReport.ReportEmbeddedResource = "GUI.ReportViews.rpNoHocPhi_By_MSSV.rdlc"; } else { if (ktra == 7) { CTXHBUS ctxhBUS = new CTXHBUS(); ReportDataSource reportDataSource = new ReportDataSource(); reportDataSource.Name = "dsCTXH_By_MSSV"; reportDataSource.Value = ctxhBUS.getHDCTXHByMaSV(maSV); reportViewer1.LocalReport.DataSources.Add(reportDataSource); this.reportViewer1.LocalReport.ReportEmbeddedResource = "GUI.ReportViews.rpCTXH_By_MSSV.rdlc"; } else { tong = "0"; ViPhamBUS vpBUS = new ViPhamBUS(); ReportDataSource reportDataSource = new ReportDataSource(); reportDataSource.Name = "dsViPham_By_MSSV"; reportDataSource.Value = vpBUS.getVPByMaSV(maSV); reportViewer1.LocalReport.DataSources.Add(reportDataSource); this.reportViewer1.LocalReport.ReportEmbeddedResource = "GUI.ReportViews.rpViPham_By_MSSV.rdlc"; } } ReportParameter[] rp = new ReportParameter[4]; rp[0] = new ReportParameter("MaSV", maSV); rp[1] = new ReportParameter("HoTen", hoTen); rp[2] = new ReportParameter("Tong", tong); rp[3] = new ReportParameter("MaLop", maLop); reportViewer1.LocalReport.SetParameters(rp); }
public frmQLHocPhan() { mhBUS = new MonHocBUS(); hpBUS = new HocPhanBUS(); svBUS = new SinhVienBUS(); dtBUS = new DIemThiBUS(); gvBUS = new GiangVienBUS(); InitializeComponent(); LoadData(); this.txtMaSV.AutoCompleteMode = AutoCompleteMode.Suggest; this.txtMaSV.AutoCompleteSource = AutoCompleteSource.CustomSource; var lstMSSV = svBUS.getMSSV(); AutoCompleteStringCollection AutoComp = new AutoCompleteStringCollection(); foreach (var sv in lstMSSV) { AutoComp.Add(sv); } this.txtMaSV.AutoCompleteCustomSource = AutoComp; }