Release 10.1A: OpenEdge Development:
Progress Dynamics Managers API Reference

> ## changePassword

> This procedure changes a user’s password, making all the relevant checks to the password.

> This procedure first checks that the passed-in user is valid and not disabled (either on the user record or the user category record). The procedure then validates that the old password is correct, similar to the `checkUser` procedure, and returns an error if it is not valid.

> Providing the old password is `OK`, the new password is then validated according to the rules set up on the system or user record. It checks password minimum length and the password history if enabled. If everything is correct, the new password is saved for the user and the appropriate user details updated. If the password was expired, the expiration details are reset.

> Location: af\app\afsecmngrp.i

> Parameters:

> `INPUT pdUserObj AS DECIMAL`

> The user object number, if known.

> `INPUT pcLoginName AS CHARACTER`

> The user login name, if known.

> `INPUT pcOldPassword AS CHARACTER`

> The old password (encoded).

> `INPUT pcNewPassword AS CHARACTER`

> The new password (encoded).

> `INPUT plExpired AS LOGICAL`

> The password expired flag.

> `INPUT piLength AS INTEGER`

> The number of password characters entered in the new password.

> `OUTPUT pcError AS CHARACTER`

> Any failure reason (standard Dynamics-formatted error).

> Notes: None

> Examples: See the main block in `af\cod2\aftemcpasw.w`.

Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095