Skip to content

Latest commit

 

History

History
58 lines (40 loc) · 1.29 KB

EnumProcesses.md

File metadata and controls

58 lines (40 loc) · 1.29 KB

Home

Function name : EnumProcesses

Group: Performance Monitoring - Library: psapi


The EnumProcesses function retrieves the process identifier for each process object in the system.


Code examples:

Enumerating Processes -- WinNT

Declaration:

BOOL EnumProcesses(
  DWORD *lpidProcess,  // array of process identifiers
  DWORD cb,            // size of array
  DWORD *cbNeeded      // number of bytes returned
);  

FoxPro declaration:

DECLARE INTEGER EnumProcesses IN psapi;
	STRING  @ lpidProcess,;
	INTEGER   cb,;
	INTEGER @ cbNeeded  

Parameters:

lpidProcess [out] Pointer to an array that receives the list of process identifiers.

cb [in] Specifies the size, in bytes, of the lpidProcess array.

cbNeeded [out] Receives the number of bytes returned in the lpidProcess array.


Return value:

If the function succeeds, the return value is nonzero. If the function fails, the return value is zero.


Comments:

Windows NT/2000/XP: Included in Windows NT 4.0 and later.
Windows 95/98/Me: Unsupported.