コード例 #1
0
        public void btnSubmit_Click(object sender, EventArgs e)
        {
            try
            {
                //RECUPERATION DES VALEURS MODIFIEES
                Client Utilisateur = (Client)Session["Client"];
                string idclient    = Utilisateur.IdClient.ToString();
                string nom         = this.txtNom.Text.Trim().ToUpper();
                string prenom      = this.txtPrenom.Text.Trim();
                string password    = this.txtPassword2.Text.Trim();
                string email       = this.txtEmail.Text.Trim();
                string telephone   = this.txtTelephone.Text.Trim();
                bool   type        = this.cbxProprio.Checked;

                //EXECUTION DE LA DAO
                DaoClient daoClient = new DaoClient();
                daoClient.UpdateClient(idclient, nom, prenom, password, email, telephone, type);
                Session["Client"] = daoClient.GetUtilisateurId(Convert.ToInt32(idclient));
                Response.Redirect("BackendEspaceClient.aspx", false);
            }
            catch (Exception ex)
            {
                ((backend)Page.Master).AddError(ex);
            }
        }