IADsUser::SetPassword

Sets the user's password to a specified value.

HRESULT IADsUser::SetPassword(
  BSTR bstrOldPassword,  //The old password
  BSTR bstrNewPassword,  //The new password
);
 

Parameter

bstrOldPassword
[in] The old password definition.
bstrNewPassword
[in] The new password definition.

Return Values

This method supports the standard return values E_FAIL and E_UNEXPECTED, as well as the following:

S_OK
The SetPassword command has been successfully issued.

QuickInfo

  Windows NT: Use version 4.0 and later.
  Windows CE: Unsupported.
  Header: Declared in iads.h.

See Also

IADsUser, ADSI User Object