I am trrying to run a scheduled job to delete a cloned VM.
Every time I run Get-VM <..........VM Name...........> | remove-vm -deletefromdisk -confirm:$false
But the VM goes Orphaned - files are deleted from the disks.
also tried
Get-VM <.....VM Name...........> | Remove-VM -DeletePermanently -Confirm:$false
gives same results.