Skip to content

Latest commit

 

History

History
49 lines (33 loc) · 1.36 KB

LocalSize.md

File metadata and controls

49 lines (33 loc) · 1.36 KB

Home

Function name : LocalSize

Group: Memory Management - Library: kernel32


The LocalSize function returns the current size of the specified local memory object, in bytes.


Code examples:

Retrieving local computer and user names
Retrieving the name of the default printer for the current user on the local computer (Win NT/XP)
GetFileOwner - Get the owner of an NTFS file
Reading security permissions for NTFS files and folders

Declaration:

UINT LocalSize(
  HLOCAL hMem
);  

FoxPro declaration:

DECLARE LONG LocalSize IN kernel32 INTEGER hMem  

Parameters:

hMem [in] Handle to the local memory object. This handle is returned by the LocalAlloc, LocalReAlloc, or LocalHandle function.


Return value:

If the function succeeds, the return value is the size of the specified local memory object, in bytes.


Comments:

The local functions are slower than other memory management functions and do not provide as many features. Therefore, new applications should use the heap functions.