Here is the simple powershell script to grab email address from AD. In a text file,just put username there.
# Q's email script
$names=get-content c:\pc.txt
foreach ($name in $names) {
Get-ADUser $name -Properties mail | select mail
}
Here is the simple powershell script to grab email address from AD. In a text file,just put username there.
# Q's email script
$names=get-content c:\pc.txt
foreach ($name in $names) {
Get-ADUser $name -Properties mail | select mail
}