回复 9# pusofalse
#include <array.au3>
Global Const $tagMEMORYSTATUSEX = "dword Length;dword MemoryLoad;" & _
"uint64 TotalPhys;uint64 AvailPhys;uint64 TotalPageFile;uint64 AvailPageFile;" & _
"uint64 TotalVirtual;uint64 AvailVirtual;uint64 AvailExtendedVirtual"
Local $tMem = DllStructCreate($tagMEMORYSTATUSEX)
Local $iMem = DllStructGetSize($tMem)
DllStructSetData($tMem, 1, $iMem)
DllCall("kernel32.dll", "none", "GlobalMemoryStatusEx", "ptr", $tMem)
Local $aMem[7]
$aMem[0] = DllStructGetData($tMem, 2)
$aMem[1] = DllStructGetData($tMem, 3)
$aMem[2] = DllStructGetData($tMem, 4)
$aMem[3] = DllStructGetData($tMem, 5)
$aMem[4] = DllStructGetData($tMem, 6)
$aMem[5] = DllStructGetData($tMem, 7)
$aMem[6] = DllStructGetData($tMem, 8)
_ArrayDisplay($aMem)
|