示例#1
0
        public void LOAD_LoaiXe()
        {
            ListPtb_LoaiXe = new List <PictureBox>();

            PtbXe1.BackgroundImage = BITMAP(Properties.Resources.Xe1);
            PtbXe2.BackgroundImage = BITMAP(Properties.Resources.Xe2);
            PtbXe3.BackgroundImage = BITMAP(Properties.Resources.Xe3);
            PtbXe4.BackgroundImage = BITMAP(Properties.Resources.Xe4);
            PtbXe5.BackgroundImage = BITMAP(Properties.Resources.Xe5);
            PtbXe6.BackgroundImage = BITMAP(Properties.Resources.Xe6);
            PtbXe7.BackgroundImage = BITMAP(Properties.Resources.Xe7);

            ListPtb_LoaiXe.Add(PtbXe1);
            ListPtb_LoaiXe.Add(PtbXe2);
            ListPtb_LoaiXe.Add(PtbXe3);
            ListPtb_LoaiXe.Add(PtbXe4);
            ListPtb_LoaiXe.Add(PtbXe5);
            ListPtb_LoaiXe.Add(PtbXe6);
            ListPtb_LoaiXe.Add(PtbXe7);

            int count = ListPtb_LoaiXe.Count;

            for (int i = 0; i < count; ++i)
            {
                ListPtb_LoaiXe[i].Visible = true;
                ListPtb_LoaiXe[i].BackgroundImageLayout = ImageLayout.Stretch;
                ListPtb_LoaiXe[i].Tag = i.ToString();
            }

            BNL_ALL    BNL         = new BNL_ALL();
            List <int> List_LoaiXe = new List <int>();

            List_LoaiXe = BNL.List_LoaiXe(LoaiXe);
        }
示例#2
0
        public void CheckPanel()
        {
            BNL_ALL      item       = new BNL_ALL();
            List <Panel> ListPannel = new List <Panel>();

            ListPannel = ListPanel;
            Thu        = item.Date(Datetime);

            if (Thu != 8)
            {
                UpdateItem();
            }
            ListPannel[Thu - 2].BackColor = Color.Blue;
            for (int i = Thu - 3; i >= 0; --i)
            {
                ListPannel[i].BackColor = Color.Red;
            }
        }
示例#3
0
        public void LoadTextBox()
        {
            List <string> Acc  = new List <string>();
            BNL_ALL       item = new BNL_ALL();

            AutoCompleteStringCollection Auto = new AutoCompleteStringCollection();

            txtID.AutoCompleteMode   = AutoCompleteMode.SuggestAppend;
            txtID.AutoCompleteSource = AutoCompleteSource.CustomSource;

            Acc = item.Account_Clone();

            foreach (string str in Acc)
            {
                Auto.Add(str);
            }
            txtID.AutoCompleteCustomSource = Auto;
        }
示例#4
0
        public void RanDom_Qua()
        {
            lbl8.Text = "X 1";
            int     ran  = 0;
            BNL_ALL item = new BNL_ALL();
            Image   img  = null;

            ran = item.RanDom(1, 8);

            switch (ran)
            {
            case 1:
            {
                img   = Properties.Resources._1;
                text += ",1";
                break;
            }

            case 2:
            {
                img   = Properties.Resources._2;
                text += ",2";
                break;
            }

            case 3:
            {
                img   = Properties.Resources._3;
                text += ",3";
                break;
            }

            case 4:
            {
                img   = Properties.Resources._4;
                text += ",4";
                break;
            }

            case 5:
            {
                img   = Properties.Resources._5;
                text += ",5";
                break;
            }

            case 6:
            {
                img   = Properties.Resources._6;
                text += ",6";
                break;
            }

            case 7:
            {
                img   = Properties.Resources._7;
                text += ",7";
                break;
            }

            case 8:
            {
                img  = Properties.Resources._8;
                text = "10";
                break;
            }
            }

            if (ran == 8)
            {
                lbl8.Text = "X 10";
            }
            Image Pannel = LoadImage(img, PanelQua.Size.Width, PanelQua.Size.Height);

            PanelQua.BackgroundImage = Pannel;
        }
示例#5
0
        public void CheckBox()
        {
            BNL_ALL item = new BNL_ALL();

            item.Check(txtID.Text);
        }