GetMemoryInfo
int GetMemoryInfo (unsigned long *percentLoad, size_t *totalPhysical, size_t *totalPageFile, size_t *totalVirtual, size_t *availablePhysical, size_t *availablePageFile, size_t *availableVirtual);
Purpose
This function determines the size of the Windows operating system's Physical, Page File, and Virtual memory, as well as the portions of each which are available to the calling process.
(Linux) This function is not supported.
Parameters
Output | ||
Name | Type | Description |
percentLoad | unsigned long | Returns the load on available memory as a percentage. This parameter may be NULL. |
totalPhysical | size_t | Returns the total physical system memory in bytes. This parameter may be NULL. |
totalPageFile | size_t | Returns the total system Page File memory in bytes. This parameter may be NULL. |
totalVirtual | size_t | Returns the total virtual system memory in bytes. This parameter may be NULL. |
availablePhysical | size_t | Returns the available physical system memory in bytes. This parameter may be NULL. |
availablePageFile | size_t | Returns the available Page File size in bytes. This paramater may be NULL. |
availableVirtual | size_t | Returns the available virtual system memory in bytes. This parameter may be NULL. |
Return Value
Name | Type | Description |
status | int | The status code that the function returns. 0 indicates success. A negative value indicates an error. This function may return a Programmer's Toolbox or UI Library error code. Call GetGeneralErrorString to obtain a text description of the error. |
Additional Information
Library: Programmer's Toolbox
Include file: toolbox\toolbox.h
LabWindows/CVI compatibility: LabWindows/CVI 5.5 and later