Invoke-Command -ComputerName DESKTOP-46AVB2C -ScriptBlock { Get-Process -name powershell } | Stop-Process Invoke-Command -ComputerName CST1600 -ScriptBlock { Get-Process -name powershell } -User Set-Item WSMan:\localhost\Client\TrustedHosts -Value 'CST1600' $ps = Invoke-Command -ComputerName DESKTOP-46AVB2C -ScriptBlock { Get-Process -name powershell } Enter-PSSession -ComputerName DESKTOP-46AVB2C start-job -scriptblock { gci } start-job -scriptblock { gci -WorkingDirectory /Windows } start-job -scriptblock { gci /Windows } Install-Module -Name ThreadJob start-threadjob -scriptblock { gci } invoke-command -computername DESKTOP-46AVB2C -ScriptBlock { get-process } -asjob -jobname MyRemoteJob get-job receive-job -id 1 receive-job -id 3 –keep receive-job -name myremotejob | sort-object PSComputerName | Format-Table -groupby PSComputerName receive-job -Name rj –keep receive-job -name rj | sort-object PSComputerName | Format-Table -groupby PSComputerName invoke-command -command { nothing } -hostname notonline -asjob -jobname ThisWillFail