Re: CreateProcess leaves child windows on rear



I still don't see anything that would cause that.

AliR.

<hq4000@xxxxxxxxxxx> wrote in message
news:1174406656.012660.34880@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
The rest just waiting for the created process to complete and then
shutdown.

if( ProcessInformation.hProcess )
{
DWORD Ret = WaitForSingleObject( ProcessInformation.hProcess,
INFINITE );
DWORD ExitCode;

GetExitCodeProcess( ProcessInformation.hProcess, &ExitCode );
GetExitCodeThread( ProcessInformation.hThread, &ExitCode );
CloseHandle( ProcessInformation.hProcess );
CloseHandle( ProcessInformation.hThread );
}
else
{

}
return 0;




.



Relevant Pages

  • Re: CreateProcess leaves child windows on rear
    ... INFINITE); ... GetExitCodeProcess(ProcessInformation.hProcess, &ExitCode); ... CloseHandle(ProcessInformation.hProcess); ...
    (microsoft.public.vc.mfc)
  • Re: CreateProcess leaves child windows on rear
    ... The exit code is not used, and in any case rarely has meaning for a Windows app, so ... GetExitCodeProcess(ProcessInformation.hProcess, &ExitCode); ... CloseHandle(ProcessInformation.hProcess); ...
    (microsoft.public.vc.mfc)
  • Re: ProcessId vs Handle
    ... > Until you call CloseHandle or your process ends, whichever comes first. ... If the process handle were to be invalid after a process ends, ... GetExitCodeProcess would have little value. ...
    (microsoft.public.vb.winapi)