Export (0) Print
Expand All

PeerIdentitySetFriendlyName function

The PeerIdentitySetFriendlyName function modifies the friendly name for a specified peer identity. The friendly name is the human-readable name.

Syntax


HRESULT WINAPI PeerIdentitySetFriendlyName(
  _In_  PCWSTR pwzIdentity,
  _In_  PCWSTR pwzFriendlyName
);

Parameters

pwzIdentity [in]

Specifies a peer identity to modify.

pwzFriendlyName [in]

Specifies a new friendly name. Specify NULL or an empty string to reset a friendly name to the default value, which is the Unicode version of the peer name.

Return value

If the function call succeeds, the return value is S_OK. Otherwise, it returns one of the following values.

Return codeDescription
E_INVALIDARG

One of the parameters is not valid.

E_OUTOFMEMORY

There is not enough memory to perform the specified operation.

PEER_E_NO_KEY_ACCESS

Access to the peer identity or peer group keys is denied. Typically, this is caused by an incorrect access control list (ACL) for the folder that contains the user or computer keys. This can happen when the ACL has been reset manually.

PEER_E_NOT_FOUND

A peer identity that matches a specified name cannot be found.

 

Requirements

Minimum supported client

Windows XP with SP2 [desktop apps only]

Minimum supported server

None supported

Version

Windows XP with SP1 with the Advanced Networking Pack for Windows XP

Header

P2P.h

Library

P2P.lib

DLL

P2P.dll

See also

PeerIdentityGetFriendlyName

 

 

Community Additions

ADD
Show:
© 2015 Microsoft