Did you know there is a tool called dsquery????? DID YOU???
OH MY GOSH!!! This is the best tool EVER! (for AD queries.)
Why didn't I know about this tool before? This tool can do all SORTS of stuff! And you can combine it with some other tools like DSMOD, etc...
It can also do ldap queries, althought the out put, using the -o option, is limited to just a four things. Basically it is for getting back account names, not certain attributes, so vbscript will still be useful in that case.
I just looked this up and it is part of the "Directory Service Command-line Tools" suite. Here is a list of the tools:
Directory Service command-line tools help:
dsadd /? - help for adding objects.
dsget /? - help for displaying objects.
dsmod /? - help for modifying objects.
dsmove /? - help for moving objects.
dsquery /? - help for finding objects matching search criteria.
dsrm /? - help for deleting objects.
Also, here is a primer from MS:
http://support.microsoft.com/kb/322684