DirectoryEntry::MoveTo Method (DirectoryEntry^)
.NET Framework (current version)
Moves this DirectoryEntry object to the specified parent.
Assembly: System.DirectoryServices (in System.DirectoryServices.dll)
Parameters
- newParent
-
Type:
System.DirectoryServices::DirectoryEntry^
The parent to which you want to move this entry.
| Exception | Condition |
|---|---|
| InvalidOperationException | The specified DirectoryEntry is not a container. |
If UsePropertyCache is true, call the CommitChanges method on the new object to make the move permanent.
DirectoryServicesPermission
To move the entry.
.NET Framework
Available since 1.1
Available since 1.1
Show: