Compartir a través de


Navigating to the Parent Object

DirectoryEntry also has a Parent property used to navigate from the object to which you are connected to its parent object.

The following code example shows how to navigate to the parent object.

Dim parent As DirectoryEntry = entry.Parent
 Console.WriteLine(parent.Name)
DirectoryEntry parent = ent.Parent;
Console.WriteLine(parent.Name);

See Also

Reference

System.DirectoryServices
DirectoryEntry

Concepts

Navigating the Directory

Send comments about this topic to Microsoft.

Copyright © 2007 by Microsoft Corporation. All rights reserved.