DirectorySearcher, FindAll more than 1000 results???

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hi,

i must skip throug all of my contacts in AD and check if targetAddress =
entry in the array of ProxyAddress.

DirectorySearcher.FindAll() methode returns just 1000 elemets, but i have
much more contacts to loop throug in AD. how can i get all of the contacts? i
tried to set the sizelimit of my searcher to 100.000 but the find all method
returnd just 1.000 objects.

thanks
 
Use DirectorySearcher.SizeLimit property.

<msdn>
If you set SizeLimit to a value that is larger than the server-determined
default of 1000 entries, the server-determined default is used.
</msdn>

hi,

i must skip throug all of my contacts in AD and check if targetAddress =
entry in the array of ProxyAddress.

DirectorySearcher.FindAll() methode returns just 1000 elemets, but i have
much more contacts to loop throug in AD. how can i get all of the contacts?
i
tried to set the sizelimit of my searcher to 100.000 but the find all method
returnd just 1.000 objects.

thanks
 
You have to perform a paged seach, you can't exceed the server side limit of
1000 objects returned.
See DirectorySearcher.PageSize property in MSDN.

Willy.
 
thanks, i will try this

Willy Denoyette said:
You have to perform a paged seach, you can't exceed the server side limit of
1000 objects returned.
See DirectorySearcher.PageSize property in MSDN.

Willy.
 
Back
Top