| || |
Re: API - DLL
I have not attempted to access this API call, but I do have some questions about how you are implementing the call to TerminateProcess().
TerminateProcess() takes two parameters: hProcess, which is a handle to the process, and uExitCode, which is the exit code for the process and for all threads associated with the process. How are you acquiring the handle to the process, and does this handle have PROCESS_TERMINATE access?
ExitProcess() is the recommended method for terminating a process, as the integrity of global data used by DLLs may be compromised by a call to TerminateProcess().
If you are ultimately successful at "killing" a process from within Silk, I would be interested in knowing how you implemented this functionality.
Sr. Software Test Automation Engineer
Home Networking Operations
API - DLL
I'm trying to use the TerminateProcess API call to "kill" an application on Win95/98/NT.
Has this ever worked for anyone?
I'm not sure if my declarations are incorrect, the calls I am making, or Silk itself.
Any help would be appreciated.
Re: API - DLL
I wanted to reply earlier but was to busy at work. I dug up the following code I had written in the past. It works for me. Though ExitProcess is the cleaner way. The handle that I am passing in to killapp is the handle from Silk's GetHandle() method. Hope this helps.