示例#1
0
        /// <summary>
        /// 修改密码
        /// </summary>
        /// <param name="te_Id">ID</param>
        /// <param name="te_OldPwd">原密码</param>
        /// <param name="te_NewPwd">新密码</param>
        /// <param name="te_ReNewPwd">重复密码</param>
        /// <param name="lblMessage">返回消息</param>
        public void  ChangePwd(string te_Id, string te_OldPwd, string te_NewPwd, string te_ReNewPwd, Label lblMessage)
        {
            int returnMessge = teacher.ChangePwd(te_Id, te_OldPwd, te_NewPwd, te_ReNewPwd);

            switch (returnMessge)
            {
            case -1: lblMessage.Text = "两次输入的密码不一致!";
                break;

            case -2: lblMessage.Text = "密码错误!";
                break;

            case 1: lblMessage.Text = "密码修改成功!";
                break;

            case 0: lblMessage.Text = "密码修改失败,请重试!";
                break;
            }
        }