Hugo,
Thanks for the kick in the right direction. I must have been doing something else braindead to be getting the errors I was yesterday.
Department must be a custom AD property that our AD admin has setup.
>David,
>
>
>for each loUser in loUsers
> ? loUser.DS_CN, loUser.DS_SAMAccountName
>endfor
>
>
>It works fine for me either way (But, for some unknown to me reason, we do not have the ds_department, at least we do not have it populated). Usually the ExecQuery does not give an error even when there is a syntax error in the WQL statement (not that I see one in yours), but the error comes when you try to use the result set. What does loUsers.Count return?