Bulk change attributes on AD with PowerShell

Change attributes with PowerShell

John Savill

March 11, 2017

1 Min Read
Bulk change attributes on AD with PowerShell

Q. How can I easily make bulk changes to objects in AD using PowerShell based on certain attributes?

A. The Get-ADUser cmdlet has the ability to find objects based on a certain filter which can be based on the user attributes. These objects can then be sent through the pipeline to other cmdlets. For example below any user in a certain department has their location changed:

Get-ADUser -Filter {Department -like '*00*'} | Set-Aduser -Replace @{msExchUsageLocation="UK"}

About the Author(s)

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like