IUserProfiles.SetActiveProfile Method
Function SetActiveProfile( _
ByVal profileID As String, _
ByVal password As String _
) As IUserProfile
This language is not supported or no code example is available.
Parameters
- profileID
- string
The ID of the profile to be activated.
- password
- string
The password for the profileID. May be null reference (Nothing in Visual Basic) or an empty string, in which case the method will try to use the saved password, if any.
Return Value
IUserProfileThe newly activated profile.
Exception type | Condition |
---|---|
The profileID:
Or the password is invalid. |
|
Another problem occurred. |
Before the profile is switched, the password must be validated.
The authentication will pass if one of the following is true:
- the password is correct or
- the password is null reference (Nothing in Visual Basic) or an empty string and the password is not required,
for example it was already saved.
This method updates the ActiveProfile property.
There's no need to call IEstimate.CheckAndRepaint, the UI will be updated automatically.