[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Adding bulk SMTP addresses to distribution group in Exchange

Posted on 2016-08-24
3
Medium Priority
?
66 Views
Last Modified: 2016-08-24
Hi Folks,

I'm trying to bulk add a group of SMTP addresses to a distribution group.  The CSV content is such:

user1@systems.com,user2@systems.com,user3@systems.com

Import-CSV D:\Scripts\Test\dist-list.csv | ForEach {Add-DistributionGroupMember -Identity "ALLKSATestStaff" -Member $_}

Open in new window


When I run this through the Exchange Management Shell, it executes without any errors, but the distribution group is not updated - any ideas?

Thanks in advance
0
Comment
Question by:khanfe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 29

Assisted Solution

by:Michael Pfister
Michael Pfister earned 1000 total points
ID: 41768741
Import-CSV expects each entry in a seperate line.


i.e.


user1@systems.com
user2@systems.com
user3@systems.com
0
 
LVL 16

Accepted Solution

by:
FOX earned 1000 total points
ID: 41768748
name the header that contains your email addresses Alias
Import-CSV "D:\Scripts\Test\dist-list.csv" | ForEach {Add-DistributionGroupMember -Identity "ALLKSATestStaff" -Member $_.Alias}
0
 

Author Comment

by:khanfe
ID: 41768761
Thanks folks - Both your suggestions worked for the different issues - it's now working!
0

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

New style of hardware planning for Microsoft Exchange server.
On September 18, Experts Exchange launched the first installment of the Help Bell, a new feature for Premium Members, Team Accounts, and Qualified Experts. The Help Bell will serve as an additional tool to help teams increase question visibility.
In this video we show how to create a mailbox database in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Servers >> Data…
To show how to create a transport rule in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Mail Flow >> Rules tab.:  To cr…

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question