thanks. That's what I was looking for.

The other post using the Quest tools works too but I wanted to do it without 
using Quest.

From: listsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com] On 
Behalf Of Mathieu Kindelberger
Sent: Tuesday, July 22, 2014 9:54 AM
To: scripting@lists.myitforum.com
Subject: [scripting] RE: Copy all AD Group Members to Another Group

Hi John,
You can use this command : Get-ADGroup GroupA -properties members | foreach 
{Add-ADGroupMember -id GroupB -MEMBERS ($_.Members) }
Best regards

From: listsad...@lists.myitforum.com<mailto:listsad...@lists.myitforum.com> 
[mailto:listsad...@lists.myitforum.com] On Behalf Of Marcum, John
Sent: mardi 22 juillet 2014 16:33
To: Scripting List 
(scripting@lists.myITforum.com<mailto:scripting@lists.myITforum.com>)
Subject: [scripting] Copy all AD Group Members to Another Group

I'm sure this is really easy but.... I need to copy all of the users in Group A 
to Group B with PoSh. How do I do that?

I see that Get-ADGroup GroupA -properties members gets me all the members and 
Add-ADGroupMember -Identity GroupB would be used to add the members into the 
second group. How do I pipe the members out and in?




________________________________
        John Marcum
            MCITP, MCTS, MCSA
              Desktop Architect
   Bradley Arant Boult Cummings LLP
________________________________
      [H_Logo]


________________________________

Confidentiality Notice: This e-mail is from a law firm and may be protected by 
the attorney-client or work product privileges. If you have received this 
message in error, please notify the sender by replying to this e-mail and then 
delete it from your computer.


________________________________

Confidentiality Notice: This e-mail is from a law firm and may be protected by 
the attorney-client or work product privileges. If you have received this 
message in error, please notify the sender by replying to this e-mail and then 
delete it from your computer.

________________________________

Confidentiality Notice: This e-mail is from a law firm and may be protected by 
the attorney-client or work product privileges. If you have received this 
message in error, please notify the sender by replying to this e-mail and then 
delete it from your computer.





Reply via email to