Reputation: 3
I am trying to fetch details of the members of specific group in AD. Below is the cmdlet I am using
Get-ADGroupMember <GroupName> -Property members
It throws the below error:
Get-ADGroupMember : A parameter cannot be found that matches parameter name 'Property'.
The cmdlet is working fine without the option "Property". Is there anything that I need to install to use this option. Currently I am working on Windows Server 2012 R2.
Upvotes: 0
Views: 79
Reputation: 174445
If you want the raw members
property, you should use Get-ADGroup
instead of Get-ADGroupMember
:
Get-ADGroup groupname -Property members
or, if you want only the member values:
(Get-ADGroup groupname -Property members).members
Upvotes: 1