Share via


IOlkAccountHelper::GetIdentity

Gets the profile name of an account.

Quick Info

See IOlkAccountHelper.

HRESULT IOlkAccountHelper::GetIdentity (  
    LPWSTR pwszIdentity, 
    DWORD *pcch 
);

Parameters

  • pwszIdentity
    [in][out] The profile name.
  • pcch
    [in] [out] Upon calling this method, contains the size (in number of characters) of pwszIdentity that has been allocated. Upon return, contains the actual length, including the 0-terminating character, of the returned profile name.

Return Values

HRESULT Description

S_OK

The call succeeded.

E_OUTOFMEMORY

The returned profile name is longer than the size of pwszIdentity.

E_INVALIDARG

pcch is NULL.

Remarks

If pwszIdentity is too small to hold the profile name, it will not be set on return, and pcch will point to the size required for pwszIdentity.

See also

About the Account Management API

PidTagProfileName