I need help creating a script in PowerShell to create users in AD from a csv file. The file contains users in this format:
COMPANY,SAM-Account Name, Password, Path (OU to be placed in), First Name, Initial, Last Name, Display Name, Security Group, CannotChangePassword, PasswordNeverExpires, email address, user-principle-name
So as a sample user whos name is Joe Blow and works at EE, this is how the format is in the csv:
EE,jblow,TempPass1,"OU=EE,OU=Customers,DC=Portal,DC=local",Joe,J,Blow, Joe Blow,PORTAL.local\Customers,FALSE,TRUE,firstname.lastname@example.org,email@example.com
The users I am importing from the CSV file can be exported in another format or rearranged if it helps, thanks in advance!
Open in new window