Powershell

Add-ADPermission

1st use info

Add-ADPermission -Identity <ADRawEntryIdParameter>
 -Owner <SecurityPrincipalIdParameter>
 <COMMON PARAMETERS> 

2nd use info

Find all groups a member belongs to and Export to CSV - TEST

This is a test -

To retrieve and list all of the groups a user belongs to in Active Directory you can use the commands Get-ADPrincipalGroupMembership. This is handy but often a user has far too many groups to simply list in PowerShell. The code below will show a few ways to get this data.

Get-ADPrincipalGroupMembership -Identity UserId

This will list every group that the user belongs to but it will just zip by on the screen. I know you can scroll, but what fun is that. Try the following code to create a formatted csv file .

Pages

Subscribe to RSS - Powershell