$DOMAIN="YourDomain" $COMPUTERLIST="c:\_PowerShell\computers.txt" Read-host "Please Enter Credentials" $ADCREDENTIALS=get-credential foreach($COMPUTER in $COMPUTERLIST) { Add-computer -ComputerName $COMPUTER -DomainName $DOMAIN -Credential $ADCREDENTIALS }