public frm_BangGiaCuoc()
        {
            InitializeComponent();
            bgc              = new BangGiaCuoc();
            lBgc             = new List <BangGiaCuoc>();
            dxp              = new DiemXuatPhat();
            ttb              = new DMTuyenThueBao();
            chaytuyen        = new THUEBAO_T_ChayTuyen();
            td               = new TuDien_LoaiXe();
            lLoaiXe          = new List <TuDien_LoaiXe>();
            pnTuyen2.Visible = false;
            pnTuyen1.Visible = false;
            pnTuyen3.Visible = false;

            lueDiemXuatPhat.Properties.DataSource    = dxp.getListDiemXP();
            lueDiemXuatPhat.Properties.DisplayMember = "TenDiemXuatPhat";
            lueDiemXuatPhat.Properties.ValueMember   = "ID";

            lueChayTuyen.Properties.DataSource    = new THUEBAO_T_ChayTuyen().GetAllChayTuyen();
            lueChayTuyen.Properties.DisplayMember = "ChayTuyen";
            lueChayTuyen.Properties.ValueMember   = "Id";

            lueLoaiXe.DataSource    = td.GetDanhSachXe();
            lueLoaiXe.DisplayMember = "TenLoaiXe";
            lueLoaiXe.ValueMember   = "LoaiXeID";
        }
 private void LoadData()
 {
     try
     {
         if (DesignMode || LicenseManager.UsageMode == LicenseUsageMode.Designtime)
         {
             return;
         }
         DataTable dtXe = new DataTable();
         dtXe = _tuDienLoaiXe.GetDanhSachXe();
         if (!NoneItemAll)
         {
             DataRow dr = dtXe.NewRow();
             dr["LoaiXeID"]  = "-1";
             dr["TenLoaiXe"] = "Tất cả";
             dtXe.Rows.Add(dr);
         }
         lueSoHieuXe.Properties.DataSource    = dtXe;
         lueSoHieuXe.Properties.DisplayMember = "TenLoaiXe";
         lueSoHieuXe.Properties.ValueMember   = "LoaiXeID";
         if (dtXe.Rows.Count > 0)
         {
             lueSoHieuXe.EditValue = dtXe.Rows[0]["LoaiXeID"];
         }
     }
     catch
     {
     }
 }
        public frm_VuotGioQuyDinh()
        {
            InitializeComponent();
            TuDien_LoaiXe td = new TuDien_LoaiXe();

            lueXe.DataSource    = td.GetDanhSachXe();
            lueXe.DisplayMember = "TenLoaiXe";
            lueXe.ValueMember   = "LoaiXeID";
            vgqd = new VuotGioQuyDinh();
        }