Jump to Real's How-to Main page

Get the application PID

The PID (process identifier) is a number assigned by the OS for a running process. You can view the allowed PIDs through the Task List on NT. This number can be useful to kill a process with a suitable utility.
[local external function declaration]
FUNCTION long GetCurrentProcessId  (  )  LIBRARY "kernel32.dll"
 
[powerscript]
long ll_pid
ll_pid = GetCurrentProcessId() 
messagebox("PID" , string(ll_pid))

If you find this article useful, consider making a small donation
to show your supportfor this Web site and its content.

Written and compiled by Réal Gagnon ©1998-2005
[ home ]