Last active
May 25, 2016 19:04
-
-
Save terrytrent/912e1657940973d8606746689d91e3ab to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$UsersToReset=Import-Csv "C:\pwreset.csv" | |
foreach($User in $UsersToReset) | |
{ | |
$Password=($User.Password | ConvertTo-SecureString -AsPlainText -Force) | |
Set-ADAccountPassword -Identity $user.User -NewPassword $Password -Reset | |
Enable-ADAccount -Identity $User.User | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment