Platform SDK: Active Directory, ADSI, and Directory Services

ldap_rename_ext_s

The ldap_rename_ext_s function changes the name of an entry. This function is available effective with LDAP 3.

ULONG ldap_rename_ext_s(
  LDAP* ld,
  PWCHAR dn,
  PWCHAR NewRDN,
  PWCHAR NewParent,
  INT DeleteOldRdn,
  PLDAPControl* ServerControls,
  PLDAPControl* ClientControls
);

Parameters

ld
[in] The session handle.
dn
[in] The distinguished name of the entry to be renamed.
NewRDN
[in] The new relative distinguished name.
NewParent
[in] The new parent (allows the entry to be moved)
DeleteOldRdn
[in] TRUE if the old relative distinguished name should be deleted; FALSE if the old relative distinguished name should be retained.
ServerControls
[in] List of LDAP server controls.
ClientControls
[in] List of client controls.

Return Values

If the function succeeds, the return value is LDAP_SUCCESS.

If the function fails, it returns an error code. See Return Values for more information.

Remarks

Multithreading: Calls to ldap_rename_ext_s are thread-safe.

Requirements

  Windows NT/2000: Requires Windows NT 4.0 SP4 or later.
  Windows 95/98: Requires Windows 95 or later. Available as a redistributable for Windows 95.
  Header: Declared in Winldap.h.
  Library: Use Wldap32.lib.
  Unicode: Declared as Unicode and ANSI prototypes.

See Also

Functions, Modifying a Directory Entry