Domain.FindAllDiscoverableDomainControllers Method

Definition

Finds all of the discoverable domain controllers in this domain.

Overloads

FindAllDiscoverableDomainControllers(String)

Finds all of the discoverable domain controllers in this domain that are also in the specified site.

FindAllDiscoverableDomainControllers()

Finds all of the discoverable domain controllers in this domain.

FindAllDiscoverableDomainControllers(String)

Source:
Domain.cs
Source:
Domain.cs
Source:
Domain.cs

Finds all of the discoverable domain controllers in this domain that are also in the specified site.

public:
 System::DirectoryServices::ActiveDirectory::DomainControllerCollection ^ FindAllDiscoverableDomainControllers(System::String ^ siteName);
public System.DirectoryServices.ActiveDirectory.DomainControllerCollection FindAllDiscoverableDomainControllers (string siteName);
member this.FindAllDiscoverableDomainControllers : string -> System.DirectoryServices.ActiveDirectory.DomainControllerCollection
Public Function FindAllDiscoverableDomainControllers (siteName As String) As DomainControllerCollection

Parameters

siteName
String

The name of the site to search for the domain controllers.

Returns

A DomainControllerCollection that contains the domain controller objects that were found by this method.

Exceptions

The target server is either busy or unavailable.

siteName is an empty string.

siteName is null.

The object has been disposed.

Remarks

You can find discoverable domain controllers by querying DNS SRV records. If a domain controller does not register an SRV record for the specified site, it will not be returned by this method, even if the domain controller is physically located within that site.

All domain controllers that register an SRV record for the specified site will be returned by this method, even if they are not physically located within that site.

See also

Applies to

FindAllDiscoverableDomainControllers()

Source:
Domain.cs
Source:
Domain.cs
Source:
Domain.cs

Finds all of the discoverable domain controllers in this domain.

public:
 System::DirectoryServices::ActiveDirectory::DomainControllerCollection ^ FindAllDiscoverableDomainControllers();
public System.DirectoryServices.ActiveDirectory.DomainControllerCollection FindAllDiscoverableDomainControllers ();
member this.FindAllDiscoverableDomainControllers : unit -> System.DirectoryServices.ActiveDirectory.DomainControllerCollection
Public Function FindAllDiscoverableDomainControllers () As DomainControllerCollection

Returns

A DomainControllerCollection that contains the domain controller objects that were found by this method.

Exceptions

The target server is either busy or unavailable.

The object has been disposed.

Remarks

You can find discoverable domain controllers by querying DNS SRV records. Only those domain controllers that register the generic, non-site-specific, domain controller SRV record will be returned by this method.

See also

Applies to