ZeroMemory( &StartupInfo, sizeof( StartupInfo ) );
StartupInfo.cb = sizeof(STARTUPINFO);
CreateProcess( NULL,
commandline,
NULL,
NULL,
FALSE,
0,
NULL,
NULL,
&StartupInfo,
&ProcessInformation);
I then click a button later on to call this (while notepad is running)
GetExitCodeProcess(ProcessInformation.hProcess,&exit_status);
and it bombs out(returns 0) and GetLastError returns 6. I don't know what the 6
means, anyone? Am I calling this right(either function) Thanks!
Regards Jan
--
Jan Bares
(remove no.spam from my email address)
JPCAD Graphics Engine developer, surf to http://www.antek.cz
"Jake Richards" <jake.r...@us.bosch.com> wrote in message
news:cd5801c0c6ef$73119770$19ef2ecf@tkmsftngxa01...
Jake
Regards Jan
--
GetExitCodeProcess(ProcessInformation.hProcess,&exit_status);
.
Finally: maybe you Close(d)Handle of your process before checking its return code? If you
closed this handle, you're not gonna be able to use it after that, and indeed it becomes
invalid.
"Franek" <einst...@worldnet.att.net> wrote in message
news:3ADCF9A1...@worldnet.att.net...