Run and grab one program from another

In win32 programming in C:

What is the best way to run the win32 console program in another win32 program, and is there a program that started execution that captures the output? At the moment, I have made the output of redirecting the program to a file, but I'm sure I should open some kind of channel?

+5
source share
1 answer

Use the CreateProcessWin32 API to start the child process.

STARTUPINFO hStdInput, hStdOutput hStdError , ( , ). , , ; hStdOutput.

( hStdInput), , WaitForInputIdle.

+5

All Articles