static void TerminateProcess(Handle Process, unsigned ExitCode)
This function terminates a process.
The handle of the process being terminated.
The exit code for the process.
The exit code may later be obtained via a call to the function GetProcessExitCode.
The caller must have access ProcessAccess::Terminate.
The function ExitProcess is the preferred method of terminating execution of a process. Calling this function may leave global data in an attached dynamic link library in an indeterminate state.
Upon calling this function, the following takes place:
Child processes are not terminated.
The process remains in the system until the last handle for the process is closed.