Пример #1
0
        //hiển thị tên các lớp theo khoa đã chọn trên thanh tìm kiếm
        private void comboBoxSearchKhoa_SelectionChangeCommitted(object sender, EventArgs e)
        {
            //truyền dữ liệu khởi tạo combo box lớp trên thanh tìm kiếm
            ArrayList arr = bus.GetLop(comboBoxSearchKhoa.SelectedValue.ToString());

            comboBoxSearchLop.Items.Clear();
            foreach (string item in arr)
            {
                comboBoxSearchLop.Items.Add(item);
            }
        }
Пример #2
0
        //ánh xạ dữ liệu theo dữ liệu đã chọn của combo box khoa
        private void comboBoxKhoa_SelectionChangeCommitted(object sender, EventArgs e)
        {
            ArrayList arr = bus.GetLop(comboBoxKhoa.SelectedValue.ToString());

            comboBoxLop.Items.Clear();
            comboBoxLop.Text = "";
            foreach (string item in arr)
            {
                comboBoxLop.Items.Add(item);
            }
        }