How can I Start-Process powershell.exe with some string splitter?
问题 I want to start powershell.exe with a scriptblock like this (it's working fine): Start-Process powershell.exe { Get-Help Get-Process } But this script doesn't work: Start-Process powershell.exe { $string = "123xAbcxEFG" $split1,$split2,$split3 = $string.Split("x") Write-Output $split1 Write-Output $split2 Write-Output $split3 sleep 10 } I think I need Add-Type -AssemblyName "SomeNameSpace" , but how can I find that namespace? Any intellisense or something like this? 回答1: you can use start-job