Hello and thanks for the fast reply
i get get the process handle , by name with this code :
Code:
LPSTR szExeName = "MyProc.exe";
HANDLE hProcess;
PROCESSENTRY32 Pc = { sizeof(PROCESSENTRY32) };
HANDLE hSnapshot = CreateToolhelp32Snapshot(TH32CS_SNAPALL, 0);
if(Process32First(hSnapshot, &Pc)){
do{
if(!strcmp(Pc.szExeFile, szExeName)) {
hProcess = OpenProcess(PROCESS_ALL_ACCESS, TRUE, Pc.th32ProcessID);
}
}while(Process32Next(hSnapshot, &Pc));
}
the problem is that i need to get the process info and from that to extract the thread id
this is something i didnt find in the link you send
Thanks