Updates the password for the membership user in the Visual Guard repository.
Namespace:
Novalys.VisualGuard.Security.MembershipAssembly: Novalys.VisualGuard.Security (in Novalys.VisualGuard.Security.dll) Version: 3.2.912.1 (3.2.912.01)
Syntax
| C# |
|---|
public static bool ChangePassword( string username, string oldPassword, string newPassword ) |
| Visual Basic (Declaration) |
|---|
Public Shared Function ChangePassword ( _ username As String, _ oldPassword As String, _ newPassword As String _ ) As Boolean |
Parameters
- username
- Type: System..::.String
The user to update the password for.
- oldPassword
- Type: System..::.String
The current password for the membership user.
- newPassword
- Type: System..::.String
The new password for the membership user.
Return Value
true if the update was successful; otherwise, false.
Exceptions
| Exception | Condition |
|---|---|
| System..::.ArgumentNullException | username or oldPassword or newPasswordis null |
| System..::.ArgumentException |
oldPassword or newPassword is longer than 64 characters.
username is empty or is longer than 64 characters or contains invalid chars ('\', '/', '?', '*', '%', ';', ''', '"', ':', '|', '[', ']', '+', '=', ','). |