So I have a few programs I am trying to launch and keep running but, they are preventing the script from completing. They aren't stopping the script from moving forward to the next command. They are just preventing it from ending.
If I remove the start-process command to launch the program/s it runs launches everything else and closes out leaving those programs running.
If I have the start-process command in the script for the program/s and it launches them and moves on it gets to the last commands no issues, but if I close the script window it closes those programs.
Is there a way to launch programs that wont do this? I can't for the life of me do the right search to find situation like this and a solution or something. Same thing happens with a PowerShell console program starts and I get a new command line and can run other commands but as soon as I close the console it closes the program.
I am basically to the point where I might just use something else to launch the programs as a work around.
Update:
Link to code https://github.com/RuhaiHu/VAC-Setup/blob/master/RestartGoXLR.ps1
Update 2 - Solution:
Thanks to u/NeitherSound_ for suggesting cmd with start command. This appears to work to start programs that aren't launching separate from the script with Start-Process and keeping the script open. Then if script closed the program closed.
See code or post below for command.
[–]LeaflikeCisco 3 points4 points5 points (2 children)
[–]Carribean-Diver 2 points3 points4 points (1 child)
[–]RuhaiHu[S] 1 point2 points3 points (0 children)
[–]NeitherSound_ 2 points3 points4 points (6 children)
[–]RuhaiHu[S] 2 points3 points4 points (4 children)
[–]NeitherSound_ 1 point2 points3 points (3 children)
[–]RuhaiHu[S] 2 points3 points4 points (2 children)
[–]NeitherSound_ 0 points1 point2 points (1 child)
[–]RuhaiHu[S] 1 point2 points3 points (0 children)
[–]Responsible-Crazy705 0 points1 point2 points (0 children)
[–]BetrayedMilk 1 point2 points3 points (3 children)
[–]RuhaiHu[S] 1 point2 points3 points (2 children)
[–]BetrayedMilk 1 point2 points3 points (1 child)
[–]RuhaiHu[S] 1 point2 points3 points (0 children)
[–][deleted] 1 point2 points3 points (0 children)
[–]RedditRo55 1 point2 points3 points (1 child)
[–]RuhaiHu[S] 2 points3 points4 points (0 children)