# Get process id question (C++)



## Regicide

I am looking to get a process' ID in windows C++; not the current process ID of the application. For example, I would like to get the process ID of a program called "example.exe". Then I would like to get a handle of the process. How would I go about doing this?


----------



## Shadow2531

I don't have an answer for you, but these may help.

http://msdn.microsoft.com/library/en-us/dllproc/base/getprocessid.asp
http://www.codeproject.com/threads/getprocessid.asp


----------



## AZPC

Well me too and how to kill it process ?

for example I have exmple.exe and I want to force kill it ?


how can I use 
::TerminateProcess(---------);

??


----------

