LucD -
I know that this is an old discussion, but I have a question regarding this script. (And forgive me because I'm a PowerCLI noob). Where do you specify the hostname and portgroup/dvportgroup name in the script? Is it after the "$vm." in $vm.tVMhost and $vm.tVLAN? If you want to move the 100+ VMs to several different hosts in a cluster, do you have to run this script several times, each time using a .csv with a different list of VM names?
Thanks!