 |
VirtualAllocEx ..msdn Add comment W32 Constants Translate this page |
 |
 |
|
Reserves or commits a region of memory within the virtual address space of a specified process. |
 |
 |
| Code examples: |
 |
|
|
 |
 |
| Declaration: |
 |
 |
LPVOID WINAPI VirtualAllocEx(
__in HANDLE hProcess,
__in_opt LPVOID lpAddress,
__in SIZE_T dwSize,
__in DWORD flAllocationType,
__in DWORD flProtect
);
|
 |
 |
 |
| FoxPro declaration: |
 |
 |
DECLARE INTEGER VirtualAllocEx IN kernel32;
INTEGER hProcess,;
INTEGER lpAddress,;
LONG dwSize,;
INTEGER flAllocationType,;
INTEGER flProtect
|
 |
 |
 |
| Parameters: |
 |
hProcess [in]
The handle to a process. The function allocates memory within the virtual address space of this process.
lpAddress [in, optional]
The pointer that specifies a desired starting address for the region of pages that you want to allocate.
dwSize [in]
The size of the region of memory to allocate, in bytes.
flAllocationType [in]
The type of memory allocation -- a predefined value.
flProtect [in]
The memory protection for the region of pages to be allocated. |
 |
 |
| Return value: |
 |
| If the function succeeds, the return value is the base address of the allocated region of pages. |
 |
 |
| My comment: |
 |
The function initializes the memory it allocates to zero, unless MEM_RESET is used.
See also: VirtualFreeEx |
 |
 |
| Word Index links for the VirtualAllocEx : |
 |
|
|
 |
 |
| Translate this page: |
 |
|
 |
 |
| • |
 |
| Created: | 2012-02-07 20:08:56 | | Modified: | 2012-02-07 20:13:15 | Visited in last 7 days: 24 |