i use this command to to put a list of vmwares in memory:
$vms = Get-VM -Name (Get-Content c:\machinelist.txt)
the machinelist.txt contains this:
001*
002*
005*
all my numbered using this way:
001 machine windows xp
002 machine test visual studio
005 windows 10 beta
the * wildcard assures that the correct vmware is found.
Is it possible to leave out the "*" in the text file, and automatically let the * be added when reading the text file out?
Reason: internally in Excel we only use the number part of the vmware names and when i copy and paste this from excel in the textfile i get:
001
002
005
and we need to manually add the * after each number. (and this needs to be done lot's of time during day, and most of time with 10+ vmwares)
Hope someone has a suggestion!