User Tools

Site Tools


listing_20processes

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
listing_20processes [2018/03/31 13:19] – external edit 127.0.0.1listing_20processes [2024/01/05 00:22] (current) – external edit 127.0.0.1
Line 1: Line 1:
 =====Listing processes===== =====Listing processes=====
  
-//by Michael Hicks, June 2007//\\ \\  The Microsoft Windows API call "CreateToolhelp32Snapshot" takes, as its name suggests, a "snapshot" of the processes (programs) running. Each process may spawn multiple "threads". This code lists the running processes and provides various other details of the process such as the "process ID", the number of threads and the other "modules" (dynamic link libraries) used by the process. To keep the code short, there is no error handling. For more details about "CreateToolhelp32Snapshot" see the [[http://msdn2.microsoft.com/en-us/library/ms682489.aspx|MSDN documentation]].\\ \\ +//by Michael Hicks, June 2007//\\ \\  The Microsoft Windows API call "CreateToolhelp32Snapshot" takes, as its name suggests, a "snapshot" of the processes (programs) running. Each process may spawn multiple "threads". This code lists the running processes and provides various other details of the process such as the "process ID", the number of threads and the other "modules" (dynamic link libraries) used by the process. To keep the code short, there is no error handling. For more details about "CreateToolhelp32Snapshot" see the [[http://msdn2.microsoft.com/en-us/library/ms682489.aspx|MSDN documentation]]. 
 + 
 +<code bb4w>
         _PROCESS_ALL_ACCESS = &1F0FFF         _PROCESS_ALL_ACCESS = &1F0FFF
         _MAX_PATH = 512         _MAX_PATH = 512
Line 65: Line 67:
         SYS "CloseHandle", hModuleSnap%         SYS "CloseHandle", hModuleSnap%
         ENDPROC         ENDPROC
 +</code>
listing_20processes.1522502367.txt.gz · Last modified: 2024/01/05 00:17 (external edit)