/// <summary> /// Bouton Modifier un Client, récupère l'index du Client sélectionné et affiche ses informations dans la fenêtre. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void button_Modifier_Client_Click(object sender, EventArgs e) { Clients modif = new Clients(); iIndexSelected = Convert.ToInt32(listView_Client.Items[iIndexSelected].Text); modif = CDAO.Find(iIndexSelected); Gestion_Fiche_Client fiche_client = new Gestion_Fiche_Client(true, modif); if (fiche_client.ShowDialog() != System.Windows.Forms.DialogResult.Cancel) { Rafraichir(); } }
/// <summary> /// Bouton Ajouter un Client, ouvre une nouvelle fenêtre. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void button_Ajouter_Client_Click(object sender, EventArgs e) { Gestion_Fiche_Client fiche_client = new Gestion_Fiche_Client(false); fiche_client.ShowDialog(); Rafraichir(); }