How do I terminate a process that I created 
Author Message
 How do I terminate a process that I created

How do I terminate a process created with "CreateProcess".
"TerminateProcess" has warnings against using it. What are my alternatives?

Thanks
Tom Groszko



Tue, 01 Apr 2003 03:00:00 GMT  
 How do I terminate a process that I created

Tom
 Here's a portion of code that creates a process;  I use it for compressing
text data by creating a CAB file.

 CreateProcess("makecab.exe", "makecab MyText.txt
My_Text.sar",NULL,NULL,FALSE,NULL,NULL,NULL,&si, &piProcessC1);
 HANDLE hIsrunning1 = piProcessC1.hProcess;

 do
 {
  GetExitCodeProcess(hIsrunning1, &ExitCode1);
 }
 while(ExitCode1 == STILL_ACTIVE);
 CloseHandle(hIsrunning1);

Regards
SteveB


Quote:
> How do I terminate a process created with "CreateProcess".
> "TerminateProcess" has warnings against using it. What are my
alternatives?

> Thanks
> Tom Groszko



Tue, 01 Apr 2003 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. How to terminate a process created with CreateProcess(...)

2. how to terminate a new created process?

3. terminating thread while WIN32 socket doing recv( )

4. Terminating a child process

5. Process suddenly terminates without notification

6. terminate process

7. Debugged Process will not Terminate under Win2K

8. Process suddenly terminates without notification

9. Terminate Process and SecurityIno ?

10. Find and terminate a process under WIN98

11. How to terminate a process

12. terminating an out of process application

 

 
Powered by phpBB® Forum Software