protected void Btn_ChangePassword_Click(object sender, EventArgs e) { AdminModel adminModel = new AdminModel(); adminModel.AdminUsername = Session["adminUsername"].ToString(); adminModel.AdminPassword = this.NewPassword.Text.ToString(); AdminLogic adminLogic = new AdminLogic(); if (adminLogic.ChangePassword(adminModel)) { this.ErrMessage.Text = "<font color=red>密码修改成功!</font>"; } else { this.ErrMessage.Text = "<font color=red>密码修改失败!</font>"; } }