# Here is a simple script that moves a list of computers from a CSV file.
# Create an array from the list of computers
$computers = Import-Csv C:\bin\todisable.csv
# Using a foreach loop to process and move the computers to the new location
# Make special note of the -name parameter!
$systems = foreach ($computer in $computers)
{ get-qadcomputer -name $computer.name }
foreach ($i in $systems)
{ Move-QADObject $i.Guid -NewParentContainer 'ou=all,ou=DISABLED,dc=domain,dc=loc' }
No comments:
Post a Comment