VB取内存问题. 向各位高手求救
Private Const PROCESS_VM_READ As Long = &H10Dim hwnd As Long ' 储存 FindWindow 函数返回的句柄
Dim pid As Long ' 储存进程标识符( Process Id )
Dim pHandle As Long ' 储存进程句柄
Dim a As Integer
' 首先取得目标窗口的句柄
hwnd = FindWindow(vbNullString, "legend of mir2")
GetWindowThreadProcessId hwnd, pid
pHandle = OpenProcess(PROCESS_VM_READ, False, pid)
ReadProcessMemory pHandle, &H1D9B192, a, Len(a), 0
msgbox a '<-这里弹出对话框总是0 不知道为什么?*******************
' 关闭进程句柄
CloseHandle hProcess
End Sub
用ReadProcessMemory取 H1D9B192地方的内存 返回值给a
a为什么总是0? 为什么取不出内存地址?
请各位大侠救救小弟 感激不尽......