protected void Button1_Click(object sender, EventArgs e)
    {
        int id = int.Parse(Session["VPId"].ToString());
        leica_geosystemsVoteProjectUser modelpass = bllusername.GetModel(id);
        //int id = getid();
        string username = this.txtusername.Value;
        string passwore = modelpass.Password;
        string Trueusername = this.txtTrueusername.Value = this.txtusername.Value;
        string company = this.txtcompany.Value;
        string city = this.txtcity.Value;
        string Phone = this.txtPhone.Value;
        string email = this.txtemail.Value;

        leica_geosystemsVoteProjectUser model = new leica_geosystemsVoteProjectUser();
        model.Id = id;
        model.Username = username;
        model.Password = passwore;
        model.Trueusername = Trueusername;
        model.Company = company;
        model.City = city;
        model.Phone = Phone;
        model.Email = email;
        leica_geosystemsVoteProjectUserManager bll = new leica_geosystemsVoteProjectUserManager();
        bll.Update(model);
        Maticsoft.Common.MessageBox.ShowAndRedirect(this, "保存成功!", "RegistrationUpdate.aspx");
    }
Esempio n. 2
0
    protected void Button1_Click(object sender, EventArgs e)
    {
        if (Session["VPId"] == null || Session["VPId"].ToString() == "")
        {
            Response.Write("<script type=\"text/javascript\" language=\"javascript\">window.parent.location.href='" + component.ServerInfo.GetRootURI() + "/VoteProject/Login.aspx?LinkPage=" + Request.Url.ToString() + "';</script>");
            return;
        }
        else
        {
            int id = int.Parse(Session["VPId"].ToString());
            leica_geosystemsVoteProjectUser modelpass = bllusername.GetModel(id);
            string username = modelpass.Username;
            string passwore = discom.EncryptMD5(txtpassword.Value);
            string Trueusername = modelpass.Trueusername;
            string company = modelpass.Company;
            string city = modelpass.City;
            string Phone = modelpass.Phone;
            string email = modelpass.Email;

            leica_geosystemsVoteProjectUser model = new leica_geosystemsVoteProjectUser();
            model.Id = id;
            model.Username = username;
            model.Password = passwore;
            model.Trueusername = Trueusername;
            model.Company = company;
            model.City = city;
            model.Phone = Phone;
            model.Email = email;
            leica_geosystemsVoteProjectUserManager bll = new leica_geosystemsVoteProjectUserManager();
            bll.Update(model);
            Maticsoft.Common.MessageBox.ShowAndRedirect(this, "提交成功!", "Login.aspx?LinkPage=" + Request.Url.ToString());
        }
    }