locked
Update custom attributes in Exchange 2007 on the basis of a particular security group. RRS feed

  • Question

  • Hi all,

     

    I want to update my custom attribute 7 to "test" for all those users who are the members of a security group name "test group".

    some user's attribute 7 is already updated but i want to update it for all. can anyone please tell me how can i do that in the simplest way.

     

    Thanks in Advance.

    SSA

    Wednesday, February 2, 2011 11:51 AM

Answers

  • Get-Recipient -Filter { (memberofgroup -like "CN=Test Group,OU=DemoLab Groups,DC=demolab,DC=local") } | set-mailbox -CustomAttribute7 "Test"

     

    #Replace the DN path with your own

    • Proposed as answer by Mike Crowley Wednesday, February 2, 2011 4:09 PM
    • Marked as answer by deltathree Friday, February 11, 2011 1:40 AM
    Wednesday, February 2, 2011 4:08 PM

All replies

  • Get-Recipient -Filter { (memberofgroup -like "CN=Test Group,OU=DemoLab Groups,DC=demolab,DC=local") } | set-mailbox -CustomAttribute7 "Test"

     

    #Replace the DN path with your own

    • Proposed as answer by Mike Crowley Wednesday, February 2, 2011 4:09 PM
    • Marked as answer by deltathree Friday, February 11, 2011 1:40 AM
    Wednesday, February 2, 2011 4:08 PM
  • Dear Mike,

     

    Thanks for the Reply,

     

    But my users exist in different OU is there any way to handel all OU in a single command ?

     

    Thanks in Advance.

    SSA

    Thursday, February 3, 2011 6:32 AM
  • that's the DN for the group, not the filters for the users. 

    Mike Crowley
    Check out My Blog!

    Thursday, February 3, 2011 6:42 AM