Skip to content

Latest commit

 

History

History
63 lines (44 loc) · 1.48 KB

File metadata and controls

63 lines (44 loc) · 1.48 KB

Home

Function name : VirtualFreeEx

Group: Memory Management - Library: kernel32


Releases, decommits, or releases and decommits a region of memory within the virtual address space of a specified process.


Code examples:

Obtaining names and positions for shortcuts located on the Windows Desktop
Moving shortcut to a specified position on the Windows Desktop

Declaration:

BOOL WINAPI VirtualFreeEx(
  __in  HANDLE hProcess,
  __in  LPVOID lpAddress,
  __in  SIZE_T dwSize,
  __in  DWORD dwFreeType
);  

FoxPro declaration:

DECLARE INTEGER VirtualFreeEx IN kernel32;
	INTEGER hProcess,;
	INTEGER lpAddress,;
	LONG dwSize,;
	INTEGER dwFreeType  

Parameters:

hProcess [in] A handle to a process. The function frees memory within the virtual address space of the process.

lpAddress [in] A pointer to the starting address of the region of memory to be freed.

dwSize [in] The size of the region of memory to free, in bytes.

dwFreeType [in] The type of free operation -- a predefined value.


Return value:

If the function succeeds, the return value is a nonzero value.


Comments:

The entire range of pages originally reserved by VirtualAllocEx must be released at the same time.