Kernel32VirtualQueryEx(IntPtr, IntPtr, MemoryBasicInformation32, IntPtr) Method
Retrieves information about a range of pages within the virtual address space of a specified process.
Namespace: DevCase.Win32.NativeMethodsAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("Kernel32.dll", SetLastError = true)]
public static IntPtr VirtualQueryEx(
IntPtr hProcess,
IntPtr address,
ref MemoryBasicInformation32 refBuffer,
IntPtr length
)
<DllImportAttribute("Kernel32.dll", SetLastError := true>]
Public Shared Function VirtualQueryEx (
hProcess As IntPtr,
address As IntPtr,
ByRef refBuffer As MemoryBasicInformation32,
length As IntPtr
) As IntPtr
Dim hProcess As IntPtr
Dim address As IntPtr
Dim refBuffer As MemoryBasicInformation32
Dim length As IntPtr
Dim returnValue As IntPtr
returnValue = Kernel32.VirtualQueryEx(hProcess,
address, refBuffer, length)
public:
[DllImportAttribute(L"Kernel32.dll", SetLastError = true)]
static IntPtr VirtualQueryEx(
IntPtr hProcess,
IntPtr address,
MemoryBasicInformation32% refBuffer,
IntPtr length
)
[<DllImportAttribute("Kernel32.dll", SetLastError = true)>]
static member VirtualQueryEx :
hProcess : IntPtr *
address : IntPtr *
refBuffer : MemoryBasicInformation32 byref *
length : IntPtr -> IntPtr
No code example is currently available or this language may not be supported.
- hProcess IntPtr
-
A handle to the process whose memory information is queried.
The handle must have been opened with the QueryInformation access right,
which enables using the handle to read information from the process object.
- address IntPtr
-
A pointer to the base address of the region of pages to be queried.
This value is rounded down to the next page boundary.
To determine the size of a page on the host computer, use the GetSystemInfo function.
- refBuffer MemoryBasicInformation32
-
A pointer to a MemoryBasicInformation32 structure in which information about the
specified page range is returned.
- length IntPtr
-
The size of the buffer pointed to by the lpBuffer parameter, in bytes.
IntPtr
The return value is the actual number of bytes returned in the information buffer
If the function fails, the return value is 0.
To get extended error information, call
GetLastWin32Error.