public void TestEnregistrerPersonne(string nom, string prenom, string dateNaissance, int paysId) { Personne p = new Personne(); p.Nom = nom; p.Prenom = prenom; p.Paysid = paysId; p.Datenaissance = DateTime.Parse(dateNaissance); p.Enregistrer(); }
protected void Button1_Click(object sender, EventArgs e) { //ServiceWeb sevice = new ServiceWeb(); Personne p = new Personne(); p.Nom = this.TextBox1.Text; p.Prenom = this.TextBox2.Text; p.Datenaissance = this.Calendar1.SelectedDate; p.Paysid = int.Parse(this.DropDown1.SelectedValue); p.Enregistrer(); Response.Redirect("ListerPersonne.aspx"); }
public void EnregistrerPersonne(Personne p) { p.Enregistrer(); }