c# - Executing a PowerShell script and leaving it running -
i have powershell script that, once executed listens on port. want execute script , leave running while c# program continues run.
here have right when gets line waits until script finished (which never does).
process proc = process.start("powershell.exe", @"/k tcdrvrcunit.exe automation.txt"); proc.waitforexit(); console.writeline(proc.processname);
Comments
Post a Comment