Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Paged query UsersContent of Paged query Users.ps1MD5 Hash: 356B496505C002DB893D7A973B94CCBC |
||
$strBase = " $strFilter = "(objectCategory=user)" $strAttributes = "name" $strScope = "subtree" $strQuery = "$strBase;$strFilter;$strAttributes;$strScope" $objConnection = New-Object -comObject "ADODB.Connection" $objConnection.provider = "ADsDSOObject" $objConnection.open("modifiedConnection") $objCommand = New-Object -comObject "ADODB.Command" $objCommand.ActiveConnection = $objConnection $objCommand.Properties.item("page size") = 500 $objCommand.CommandText = $strQuery $objRecordSet = $objCommand.Execute() Do { $objRecordSet.Fields.item("name") |Select-Object Name,Value $objRecordSet.MoveNext() } Until ($objRecordSet.eof) $objConnection.Close() | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |