Get Process Status with WinApi in C (Active or Not) -
at operating system course in project have process status. coding c.
example output:
process no process id program name status handle count 1 5780 notepad.exe active 1
how can status , handle count?
get process handle using openprocess
process_query_information
desired access (or use handle obtained, possibly createprocess
), try termination status using getexitcodeprocess
. if returns still_active
, process has not terminated yet, otherwise has. don't forget close handle using closehandle
Comments
Post a Comment