loLDAP = Getobject('Winmgmts://./root/directory/ldap') loUsers = loLDAP.ExecQuery( [Select * from ds_user where ds_department = 'IT' ])But if I try this:
loUsers = loLDAP.ExecQuery( [Select ds_cn, ds_samaccountname from ds_user where ds_department = 'IT' ])It doesn't throw an error, but iterating over loUsers gives me obtuse OLE errors.