Active Directory query: 1000 record limit

From: diamond (proverka_at_microsoft.com)
Date: 06/18/04


Date: Fri, 18 Jun 2004 11:15:23 +0400

I've read that to avoid this known problem I shoud set the "Page Size"
property:

 LdapConn := TADOConnection.Create(nil);
 Comm := TADOCommand.Create(nil);
 Rec := TADODataSet.Create(nil);

 LdapConn.ConnectionString := 'Provider=ADsDSOObject;Encrypt
Password=True;Mode=Read;Bind Flags=0';
 LdapConn.LoginPrompt := false;
 Comm.ParamCheck := false;
 Comm.Connection := LdapConn;

and the following code raises error:

 Comm.Properties.Item['Page Size'].Value := 5000;
 Comm.Properties.Item['Asynchronous'].Value := True;

because there are no properties with that names.

Previous postings did not cleared how to solve this problem. Can somebody
post the working code?