WinExec running in parallel?
Posted on 1997-03-25
I need to run a small DOS application in my Win 3.1 c++ program(MS c++ 1.52). I'm using WinExec to do this.
My problem is that the line following the WinExec is an if/then statement that relies on a file that the DOS program might or might now create. IF the DOS program created the file it does one thing, else another.
What it seems to be doing is running both my program and the DOS application in parallel(Win 3.1 definition of parallel:)). I mean, it seems to be getting past the if/then statement before the DOS application has time to finish and write its output file.
Is there any way to stop the swapping of resources in windows so it only runs the DOS application? So it runs lineraly? I've tried several things including a pif file for my DOS application with priorities set to max(10000).
Thanks for any ideas!