示例#1
0
        public void ajoute(Locataire l)
        {
            string r = "INSERT INTO " + nomTable + "  VALUES(" + l.getId() + ",\"" + l.getNom() + "\"," + l.getRevenu() + ") ;";

            try
            {
                myconx.openConnexion();
                myconx.prepareCommande(r).ExecuteNonQuery();
                myconx.closeConnexion();
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
示例#2
0
 public void supprimelocataire(Locataire locataire)
 {
     this.listeDeLocataire.Remove(locataire);
     locataireDao.delete(locataire.getId());
     listeDeLocataire = locataireDao.selectTout();
 }