Powershell script to view user account and unlock the account:
[Note: must run as Domain admin to view account and have ActiveDirectory module installed]
Screenshot:

Code:
Import-Module ActiveDirectory
$val = 0
while ($val -lt 1)
{
$username = Read-Host -Prompt 'Input the user name'
get-aduser -identity $username -properties passwordlastset, passwordexpired, lockedout, lastlogon, scriptpath
Write-Host -ForegroundColor YELLOW 'Do you need to unlock?'
$confirmation = Read-Host "y/n:"
if ($confirmation -eq 'y') {
unlock-adaccount -identity $username
Write-Host -ForegroundColor YELLOW 'Unlocked :)'
} else {
Write-Host -ForegroundColor YELLOW 'Okay'
Write-Host '------------------------------'
Write-Host '------------------------------'
}
}
