DirectoryEntry.Parent Eigenschaft

Definition

Ruft das übergeordnete Element dieses Eintrags in der Active Directory Domain Services-Hierarchie ab.

public:
 property System::DirectoryServices::DirectoryEntry ^ Parent { System::DirectoryServices::DirectoryEntry ^ get(); };
public System.DirectoryServices.DirectoryEntry Parent { get; }
[System.ComponentModel.Browsable(false)]
[System.DirectoryServices.DSDescription("DSParent")]
public System.DirectoryServices.DirectoryEntry Parent { get; }
member this.Parent : System.DirectoryServices.DirectoryEntry
[<System.ComponentModel.Browsable(false)>]
[<System.DirectoryServices.DSDescription("DSParent")>]
member this.Parent : System.DirectoryServices.DirectoryEntry
Public ReadOnly Property Parent As DirectoryEntry

Eigenschaftswert

Ein DirectoryEntry Objekt, das das übergeordnete Element dieses Eintrags darstellt.

Attribute

Beispiele

Im folgenden Beispiel wird ein bestimmtes DirectoryEntry Element durchsucht und das Name Ergebnis und Parent das Ergebnis angezeigt.

Dim myADSPath As String = _
          "LDAP://onecity/CN=user,CN=Users,DC=onecity,DC=corp,DC=fabrikam,DC=com"
Dim myDirectoryEntry As New DirectoryEntry(myADSPath, UserName, SecurelyStoredPassword)

Console.WriteLine("Parent is :" + myDirectoryEntry.Parent.Path)
String myADSPath = "LDAP://onecity/CN=user,CN=Users,DC=onecity,DC=corp,DC=fabrikam,DC=com";
DirectoryEntry myDirectoryEntry=new DirectoryEntry(myADSPath, UserName, SecurelyStoredPassword);

Console.WriteLine("Parent is :"+myDirectoryEntry.Parent.Path);

Gilt für: