8 lines
126 B
PowerShell
8 lines
126 B
PowerShell
|
Param(
|
||
|
[Parameter(Mandatory=$true)]
|
||
|
[string]$VmId
|
||
|
)
|
||
|
|
||
|
$VM = Get-VM -Id $VmId -ErrorAction "Stop"
|
||
|
Suspend-VM $VM
|