Import users from CSV
-
07 Mayıs 2012 Pazartesi 18:10
hello all!
I wrote this
$OuBorn = 'OU=TESTBRAD,DC=cd1,DC=bcu,DC=edu'
$Freshmen = 'C:\csv\file.csv'
import-csv $Freshmen |`
where {new-QADUser -ParentContainer $OuBorn `
-name $_.name -sAMAccountName $_.sAMAccountName}it is to populate an ou with users listed within a csv file. Simple enough! however I get this error (same as my last error) and I don't understand why.
bradley Wyatt
Tüm Yanıtlar
-
07 Mayıs 2012 Pazartesi 19:32
Why are you using "Where"? Don't you mean "ForEach-Object"? 'Where' is a filter.
Apparently teh container eohter doesn't exist or you have a permissions issue. I suspect that you are using the incorrect DN just like before.
Use this to get the parent container.DN
Use the DN you find.
¯\_(ツ)_/¯
- Yanıt Olarak Öneren Peddy1st 07 Mayıs 2012 Pazartesi 19:35
- Düzenleyen jrvMicrosoft Community Contributor 07 Mayıs 2012 Pazartesi 19:37
- Yanıt Olarak İşaretleyen Bradley Wyatt 08 Mayıs 2012 Salı 17:46