As Administrator, In many cases you need to count members of AD groups.
The Get-ADGroupMember cmdlet gets the members of an Active Directory group. Members can be users, groups, and computers.
$users = Get-ADGroupMember -Identity 'Group Name'
$users.count
132

No comments:
Post a Comment
Note: only a member of this blog may post a comment.