
Get PID from hProcess through CreateRemoteThread?
I have an hProcess returned from ShellExecuteEx. I need the PID instead.
Apparently its very difficult to get. I understand I can use
CreateRemoteThread in some way but don't see any examples anywhere.
Can someone please tell me how to use CreateRemoteThread to call
GetCurrentProcessId and end up with a PID for hProcess?
This only has to work on Win2K and higher. Any other suggestions would be
great. I wish to stay away from CreateProcess, which is why I'm using
ShellExecuteEx.
Thanks.