Updated! Upload Hundreds of Contacts into your Exchange 2007 in 8 simple steps -
I previously posted an article on how to upload Contacts into Exchange 2007 from a CSV file (the article can be found here).
The script has always generated errors when face with situations where Contacts had Double First or Last names thanks to the white space between the names which cannot be used as an alias. So today, I revisited the script & did some research to try 'fix' this little bug.
About 10 mins into reasearching it, The Scripting Guys came to the rescue again with a brilliant article on Manipulating String Values in PowerShell.
Anyway, it was relatively simple to fix the script & here it is for download, along with the CSV file template which is bes populated using Microsoft Excel.
Download CreateContactsV2.0
The script has always generated errors when face with situations where Contacts had Double First or Last names thanks to the white space between the names which cannot be used as an alias. So today, I revisited the script & did some research to try 'fix' this little bug.
About 10 mins into reasearching it, The Scripting Guys came to the rescue again with a brilliant article on Manipulating String Values in PowerShell.
Anyway, it was relatively simple to fix the script & here it is for download, along with the CSV file template which is bes populated using Microsoft Excel.
Download CreateContactsV2.0







Worked like a charm bro .. thanks !
had to edit the script a bit cause the excel file i had contained first name and last name in the same cell casing it to fail and i wasn't about to edit 1500 names.
here are the changes i made
$entry = $_
$DN = $_.First
$a = $_.First.Replace(" ", "")
$Alias = $a
Reply to this
Glad it helped - scripts are funny like that though, for some reason they usually need to be tweaked to suit your particular requirement. This could possibly be because most scripts are developed to suit the developer's initial requirement...
Good job on the tweaking & poting the update though, nice to see feedback from other professionals out there
Reply to this
I'm glad to find this article it has all that i need.
Keep the good work.
Reply to this
Hi Johan,
This script is great.. Is there any easy way that contacts can be automatically added to groups when they are imported?
Thanks..
Reply to this
Hi Nass,
Glad you found the script useful. It is possible to manage and maintain your groups using scripts but you will have to use the ldifde tool. Unfortunately I do not have such a script as csvde has always been sufficient for my requirements (as a consultant, user administration is not something I usually work with.)
There is plenty of information available on the web that can help you build up this script.
Hope this helps.
Regards,
Johan
Reply to this