How to mass change the primary group of users in active directory with PowerShell
Introduction This very simple PS code will allow you to change the primary group of a group of users and report back who the users are you've changed through the script. Code Start-Transcript "C:\Users\UserName\Downloads\PrimaryGroupChange.log" $newPrimaryGroup = get-adgroup "NewPrimaryGroupHere" -Properties "primaryGroupToken" $oldPrimaryGroup = get-adgroup "OldPrimaryGroupHere" -Properties "primaryGroupToken" $tempUsers = get-aduser -Filter…