Пример #1
0
        private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            clmYearLevel.Items.Clear();
            List <string> yearLevels = (from r in YearLevel.GetYearLevelsByEducationLevel(cmbEducationLevel.Text) select r.YearLvl).ToList();

            foreach (var item in yearLevels)
            {
                clmYearLevel.Items.Add(item);
            }
        }
Пример #2
0
        private void LoadYearLevels()
        {
            List <string> yearlevels = YearLevel.GetYearLevelsByEducationLevel(_YearLevels, cmbEducationLevel.Text);

            cmbYearLevel.Items.Clear();
            foreach (var item in yearlevels)
            {
                cmbYearLevel.Items.Add(item);
            }
        }