Hey Folks,
I am working on a piece of code where I need to call a .ps1 script to do a background job and need the job to continue working while the .ps1 exits. I tried to make this work with Start-Process powershell.exe -ArgumentList "-Command `"&{$ScriptBlock}`""
where I defined my whole process in the $ScriptBlock. Anyhelp on this is appreciated
It terminates with an error (I can see this when i do a -NoExit)
The string is missing the terminator: ".
+ CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordEx
ception
+ FullyQualifiedErrorId : TerminatorExpectedAtEndOfString
If you find this helpful, kindly mark as answer. If you have any queries, please post back as a reply. Will look forward to your feedback. Thanking You Soumyajyoti Biswas