Share via


DirectoryEntry.NativeGuid Vlastnost

Definice

Získá identifikátor GUID DirectoryEntry, jak je vráceno zprostředkovatele.

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

Hodnota vlastnosti

Struktura Guid , která představuje identifikátor GUID objektu DirectoryEntry, který je vrácen zprostředkovatele.

Atributy

Příklady

Následující příklad ukazuje Guid vlastnosti DirectoryEntry a NativeGuid třídy . Tento příklad získá uživatelem zadaný DirectoryEntry a zobrazí jeho Guid vlastnosti a NativeGuid .

Dim myADSPath As [String] = "LDAP://onecity/CN=Users,  
             DC=onecity,DC=corp,DC=fabrikam,DC=com"  
Dim myDirectoryEntry As New DirectoryEntry(myADSPath)  

' Display the Guid and NativeGuid.  
Console.WriteLine("The GUID of the ADS object:" + myDirectoryEntry.Guid.ToString)  
Console.WriteLine("The Native GUID of the ADS" + "object:" +   
             myDirectoryEntry.NativeGuid)  
String myADSPath = "LDAP://onecity/CN=Users,  
             DC=onecity,DC=corp,DC=fabrikam,DC=com";  
DirectoryEntry myDirectoryEntry=new DirectoryEntry(myADSPath);  

// Display the Guid and NativeGuid.  
Console.WriteLine("The GUID of the ADS object:"+  
                  myDirectoryEntry.Guid);  
Console.WriteLine("The Native GUID of the ADS"+  
                  "object:"+myDirectoryEntry.NativeGuid);  
String^ myADSPath = "LDAP://onecity/CN=Users,DC=onecity,DC=corp,DC=fabrikam,DC=com";  
DirectoryEntry^ myDirectoryEntry = gcnew DirectoryEntry(myADSPath);  

// Display the Guid and NativeGuid.  
Console::WriteLine("The GUID of the ADS object: {0}", myDirectoryEntry->Guid));  
Console::WriteLine("The Native GUID of the ADS object: {0}",  
                   myDirectoryEntry->NativeGuid);  

Poznámky

NativeGuid Vlastnost použijte při vytváření vazby objektu v Active Directory Domain Services.

Poznámka

Zprostředkovatel protokolu LDAP (Lightweight Directory Access Protocol) vrátí globálně jedinečný identifikátor objektu DirectoryEntry v jiném formátu než zprostředkovatelé Internetové informační služby (IIS), Novell NetWare Directory Server (NDS) a WinNT.

Platí pro

Viz také