﻿id	summary	reporter	owner	description	type	status	milestone	component	version	severity	resolution	keywords	cc
803	ProcessGetStats documentation Improvement	Emiel Wieldraaijer		"Hi,

i want to retrieve some information about the processes running on my computer but i the help file regarding ProcessGetStats did not tell me much..so i decided to figure it out myself.. 

Here is my example code for the help file


{{{
#include <Process.au3>

Dim $Priority[6]

$Priority[0] = ""Idle/Low"" 
$Priority[1] = ""Below Normal""
$Priority[2] = ""Normal""
$Priority[3] = ""Above Normal""
$Priority[4] = ""High""
$Priority[5] = ""Realtime""

$List = ProcessList()

$TotalProcesses = $List[0][0]

Msgbox (0, ""Total processes detected: "", $TotalProcesses)

; Skip the first detection because it represents the none active systemprocesses PID = 0
for $i = 2 to $List[0][0]
	$MemoryStats = ProcessGetStats ($List[$i][1], 0)
	; Check if a process is an array because not all processes return information
	If IsArray($MemoryStats) Then
		Msgbox (0, ""ProcessStats : "", ""ProcessName = "" & $List[$i][0] & "" - MemoryUsage = ""  & Round($MemoryStats[0]/1024) & "" KB - PID = "" & $List[$i][1] & "" - Priority = "" & $Priority[(_ProcessGetPriority ($List[$i][1]))] ,0)
	Else 
		$TotalProcesses = $TotalProcesses -1 
	EndIf
Next

Msgbox (0, ""Total processes returning information: "", $TotalProcesses)
}}}

"	Feature Request	closed		Documentation		None	Rejected	ProcessGetStats	
