示例#1
0
        private void Ajouter_Enseignant_Load(object sender, EventArgs e)
        {
            DataTable       dt       = new DataTable();
            Dal_Departement Dal_Dept = new Dal_Departement();

            dt = Dal_Dept.GetAllDepartementsDataTable();

            for (int i = 0; i < dt.Rows.Count; i++)
            {
                this.Cbx_Dept.Items.Add(dt.Rows[i]["Code"]);
            }
        }
示例#2
0
 public Departement()
 {
     InitializeComponent();
     Dgv_Dept.DataSource = Dal_Dept.GetAllDepartementsDataTable();
     if (Dal_Dept.GetAllDepartementsDataTable().Rows.Count == 0)
     {
         Btn_Supprimer.Enabled = false;
         Btn_Modifier.Enabled  = false;
     }
 }