UINT GlobalFlags(hglb) | |||||
HGLOBAL hglb; | /* handle of global memory object | */ |
The GlobalFlags function returns information about the given global memory object.
hglb
Identifies the global memory object.
The return value specifies the memory-allocation flag and the lock count for the memory object, if the function is successful.
When an application masks out the lock count in the low-order byte of the return value, the return value contains one of the following allocation flags:
Value | Meaning |
GMEM_DISCARDABLE | Object can be discarded. |
GMEM_DISCARDED | Object has been discarded. |
The low-order byte of the return value contains the lock count of the object. Use the GMEM_LOCKCOUNT mask to retrieve the lock count from the return value.
The following functions can affect the lock count of a global memory object:
Increments lock count | Decrements lock count |
GlobalFix | GlobalUnfix |
GlobalLock | GlobalUnlock |