I am launching a java application (testApp.exe) using CreateProcess() win32 API. PROCESS_INFORMATION structure is returning me a process id that does not exist in the list of PIDs in taskmanager or EnumProcesses() API. I can see there is one javaw.exe is launched having some different process id. this javaw.exe process id is different from PID returned by PROCESS_INFORMATION structure.
How can I get the correct PID.
I want to launch this java application, and sometime later I want to kill this java application using PID.