Powershell to add multiple users in multiple groups

Published: 31 December 2016
on channel: Abhijit Bole
48,484
281

First create the group.csv file as mentioned below

Username,groupname
User1,group1
User2,group2
User3,group3


#=========================================================================
import-csv "C:\temp\group.csv" | ForEach-Object {add-ADGroupMember -Identity $_.groupname -Members $_.username}

#=========================================================================


On this page of the site you can watch the video online Powershell to add multiple users in multiple groups with a duration of hours minute second in good quality, which was uploaded by the user Abhijit Bole 31 December 2016, share the link with friends and acquaintances, this video has already been watched 48,484 times on youtube and it was liked by 281 viewers. Enjoy your viewing!