A quick PowerShell 2 function for a Monday evening. A function to return properties from the WinNT provider, most commonly used to enumerate local group membership.

This should also work for domain groups (using the domain as the SystemName), although if the domain is Active Directory the LDAP provider returns far more information.

The function can be copied into the prompt as is, or made into a script by dropping the opening “Function …” and closing }.

Once it’s there, you can see usage with:

And the function itself:


  1. Chris

    Thanks for posting this. I was just working on something very similar but yours is much better as usual.
    One thing I had to change to get the Quest tools to work through the pipeline is the $ComputerName variable. It would always try to pull over the computername attribute which is COMPUTER$ and was not able to get the path to the computer. Not sure if it was something i am doing wrong. When I used this line it worked before changing the variable name.
    get-qadcomputer Computername | Select dnshostname | Get-LocalGroupMember

    Thanks again for this and everything else you post. Everyday I learn more about powershell from your posts here and on EE.


  2. Ah yes, I didn’t actually test the feed from Quest, I should have remembered the Computer parameter. I’ll fix that up tomorrow when I have AD to work with again 🙂



  3. Pipelining from Get-QADComputer is fixed.


Leave a Reply

Your email address will not be published. Required fields are marked *