The GlobalSize function retrieves the current size, in bytes, of the specified global memory object.
DWORD GlobalSize( HGLOBAL hMem )
If the function succeeds, the return value is the size of the specified global memory object, in bytes.
EX1
void GlobalSize_Ex1() { DWORD nMemSize =200 ; HGLOBAL hData = GlobalAlloc(GHND,nMemSize); if(!hData) { out_str("failed to allocate memory\n"); return ; } printf("The memory resized to : %d BYTES",GlobalSize(hData)) ; GlobalFree(hData) ; }
GlobalReAlloc, GlobalReAlloc, GlobalFree, GlobalLock, GlobalUnlock
origin.h