Solved

How Can I Add an bulk an Email Address to the proxyAddresses Attribute of all users in an OU.

Posted on 2008-10-13
11
1,349 Views
Last Modified: 2008-10-19
How Can I Add an bulk an Email Address to the proxyAddresses Attribute of all users in an OU via script?

I wan to use the same mailnickname as their current primary smtp address, I just want to add a secondary with the new mail domain. Some of the users in the OU already have the address, over half do not. How can I add it to the users that do not?
0
Comment
Question by:Studio720
  • 3
  • 2
  • 2
  • +1
11 Comments
 
LVL 23

Expert Comment

by:Justin Durrant
ID: 22704700
0
 

Author Comment

by:Studio720
ID: 22704780
I saw this article, but my question about this is given the sample:

Const ADS_PROPERTY_APPEND = 3

Set objUser = GetObject _
    ("LDAP://cn=KenMyer,ou=Finance,dc=fabrikam,dc=com")

objUser.PutEx ADS_PROPERTY_APPEND, "proxyAddresses", _
    Array("kenmyer@northamerica.fabrikam.com ")

Can I change it to:

Const ADS_PROPERTY_APPEND = 3

Set objUser = GetObject _
    ("LDAP://ou=Finance,dc=fabrikam,dc=com")

objUser.PutEx ADS_PROPERTY_APPEND, "proxyAddresses", _
    Array("*@northamerica.fabrikam.com ")

to add the the mailnickname + @northamerica.fabrikam.com to all users of the Finance OU?
0
 
LVL 23

Expert Comment

by:Justin Durrant
ID: 22704813
that should work... try on a test OU first
0
Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

 

Author Comment

by:Studio720
ID: 22705107
This did not work for me.
0
 

Author Comment

by:Studio720
ID: 22706667
Can somebody help me with the example above to add a proxyaddress to all recipients in the Finance OU.
0
 
LVL 31

Expert Comment

by:Henrik Johansson
ID: 22725004
To script the objects in an OU, you nead to collect the OU as a recordset and loop through each object in the recordset.

As question is stated, it sounds like you nead to configure a recipient policy
http://support.microsoft.com/kb/319201
0
 
LVL 13

Accepted Solution

by:
ach_patil earned 500 total points
ID: 22729716
There is another easy way to do it. Instead of scripting you can use ADModify to add the proxy address.

Download it from here
http://www.codeplex.com/admodify
Tutorial
http://www.activedir.org/Articles/tabid/54/articleType/ArticleView/articleId/45/Default.aspx

Run it and select your OU... Select all users for whom you need to add the email address. In the Email Addresses tab. Add the format of the SMTP address you need. Click on Go.

I would suggest you first try it on a Test OU
0
 
LVL 13

Expert Comment

by:ach_patil
ID: 22731047
Glad it helped..

To avoid adding the SMTP address manualy everytime a user iscreated, You can also create an Email Recipient policy based on the criteria you need. This way the SMTP address is added automatically

If you are using Exchange 2003, heres how you can do it.
http://www.computerperformance.co.uk/exchange2003/exchange2003_recipient_policy.htm
http://www.msexchange.org/tutorials/Implementing-Custom-Recipient-Policies.html
0
 
LVL 31

Expert Comment

by:Henrik Johansson
ID: 22732435
As I already have suggested recipient policy, I wonder why http:#22725004 isn't accepted/included as part of solution?
0

Featured Post

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

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

This article lists the top 5 free OST to PST Converter Tools. These tools save a lot of time for users when they want to convert OST to PST after their exchange server is no longer available or some other critical issue with exchange server or impor…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles to another domain controller. Log onto the new domain controller with a user account t…
This video demonstrates how to sync Microsoft Exchange Public Folders with smartphones using CodeTwo Exchange Sync and Exchange ActiveSync. To learn more about CodeTwo Exchange Sync and download the free trial, go to: http://www.codetwo.com/excha…

813 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now