Possible Duplicate:
How do I eliminate Windows consoles from spawned processes in Python (2.7)?
Hi,
In my application I am using external console application. I am catching its output (from std out) and process it. What is happening though that every time I start this application the console window is popping out which is a problem (because I can't use the computer for anything else during the calculations). Is there any way to execute console application, catch its stdout without actually having console window to pop up? The code which is executing the console app:
p = subprocess.Popen([BCALCPATH, "-c", hand, "-t", "a", "-e", "e", "-q", "-d SWNE"], stdout = subprocess.PIPE, stderr = subprocess.STDOUT)
table = p.stdout.read().decode()
All those -c, -t etc. are argument for the console app. BCALCPATH is path to the .exe file. Thanks for help :)