Condividi tramite


DirectoryEntry.NativeGuid Proprietà

Definizione

Ottiene il GUID dell'oggetto DirectoryEntry, come restituito dal provider.

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

Valore della proprietà

Struttura Guid che rappresenta il GUID dell'oggetto DirectoryEntry, restituito dal provider.

Attributi

Esempio

Nell'esempio seguente vengono illustrate le Guid proprietà e NativeGuid della DirectoryEntry classe . Questo esempio ottiene l'oggetto specificato dall'utente DirectoryEntry e ne visualizza Guid le proprietà e 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);

Commenti

Utilizzare la NativeGuid proprietà quando si associa un oggetto in Servizi di dominio Active Directory.

Annotazioni

Il provider LDAP (Lightweight Directory Access Protocol) restituisce l'identificatore univoco globale di un oggetto DirectoryEntry in un formato diverso rispetto ai provider Internet Information Services (IIS), Novell NetWare Directory Server (NDS) e WinNT.

Si applica a

Vedi anche