anoniem Geplaatst: 24 augustus 2002 Delen Geplaatst: 24 augustus 2002 Hoe kan je opvragen hoeveel geheugen er beschikbaar is voor Windows? Is vast niet zo heel moeilijk... Quote Link naar reactie
anoniem Geplaatst: 24 augustus 2002 Auteur Delen Geplaatst: 24 augustus 2002 [quote:8d6b900161="Johan Stokking"]Hoe kan je opvragen hoeveel geheugen er beschikbaar is voor Windows? Is vast niet zo heel moeilijk...[/quote:8d6b900161] [i:8d6b900161]Geheugen[/i:8d6b900161] is nogal een ruim begrip. Bedoel je fysiek geheugen, virtueel geheugen, harde schijf/swapfile, etc. [code:1:8d6b900161] var memStatus: TMemoryStatus; begin memStatus.dwLength := SizeOf(memStatus); GlobalMemoryStatus(memStatus); ShowMessage('Memory load: ' + IntToStr(memStatus.dwMemoryLoad) + '%'); ShowMessage('Physical memory: ' + IntToStr(memStatus.dwTotalPhys)); ShowMessage('Available memory: ' + IntToStr(memStatus.dwAvailPhys)); ShowMessage('Physical store size: ' + IntToStr(memStatus.dwTotalPageFile)); ShowMessage('Available page size: ' + IntToStr(memStatus.dwAvailPageSize)); ShowMessage('Physical virtual memory: ' + IntToStr(memStatus.dwTotalVirtual)); ShowMessage('Available virtual memory: ' + IntToStr(memStatus.dwAvailVirtual)); end; [/code:1:8d6b900161] [i:8d6b900161]"The usefulness of calling the GlobalMemoryStatus function is to determine how much memory it can allocate without severely impacting other applications. By periodically getting the current memory status, you can determine whether the machine is running low on available resources. This can be very beneficial as the operating system, or your application, may have problems when there are limited resources, particularly if your application is real-time or time critical."[/i:8d6b900161] [url=http://msdn.microsoft.com/library/default.asp?url=/library/en-us/memory/base/globalmemorystatus.asp]MSDN - GlobalMemoryStatus[/url] [url=http://msdn.microsoft.com/isapi/gosupport.asp?TARGET=/support/kb/articles/Q274/5/58.asp?SD=MSDN&FR=0]GlobalMemoryStatus() Function Behavior on Systems with More than 2 GB RAM[/url] Quote Link naar reactie
anoniem Geplaatst: 24 augustus 2002 Auteur Delen Geplaatst: 24 augustus 2002 Bedankt! Ik bedoelde Physical Memory. Quote Link naar reactie
Aanbevolen berichten
Om een reactie te plaatsen, moet je eerst inloggen