Skip to content

Latest commit

 

History

History
52 lines (36 loc) · 1.8 KB

GetCurrentProcess.md

File metadata and controls

52 lines (36 loc) · 1.8 KB

Home

Function name : GetCurrentProcess

Group: Process and Thread - Library: kernel32


The GetCurrentProcess function retrieves a pseudo handle for the current process.


Code examples:

Memory usage info for current VFP session (WinNT only)
Retrieving the priority class for the current process
Using File Mapping for enumerating files opened by Visual FoxPro
Running MSDOS Shell as a child process with redirected input and output (smarter RUN command)
How to enable the SE_SHUTDOWN_NAME privilege for the application
Reading and setting system access privileges for the current process
Obtaining names and positions for shortcuts located on the Windows Desktop
How to check whether the system is 32-bit or 64-bit
How to load a user profile

Declaration:

HANDLE GetCurrentProcess(VOID);  

FoxPro declaration:

DECLARE INTEGER GetCurrentProcess;
	IN kernel32  

Parameters:

This function has no parameters.


Return value:

The return value is a pseudo handle to the current process.


Comments:

A pseudo handle is a special constant that is interpreted as the current process handle. The calling process can use this handle to specify its own process whenever a process handle is required. Pseudo handles are not inherited by child processes.