vb webQQ登陆器
2010年06月10日
'********************webQQ登陆器*****************************
'############################################################
'功能:登陆网页QQ
'作者:裴具才
'QQ:592123987
'时间:2010.6.10
'仅为学习交流使用,请勿非法使用,否则一切后果自负!
'尊重原作者请保留
'###########################################################
'***********************************************************
Dim URL1, URL2 As String
Private Sub Form_Load()
URL1 = "http://ui.ptlogin2.qq.com/cgi-bin/login?style=4&appid=1002101&no_verifyimg=1&s_url=http://web.qq.com/main.shtml?direct&f_url=loginerroralert"
URL2 = "http://web.qq.com/main.shtml?direct"
WebBrowser1.Navigate URL1
Timer1.Enabled = False
Label5.FontUnderline = True
Label5.ForeColor = vbBlue
End Sub
Private Sub Form_Resize()
WebBrowser1.Width = Me.ScaleWidth
WebBrowser1.Height = Me.ScaleHeight
End Sub
Private Sub Command1_Click()
Dim CtrlRange As Object
If WebBrowser1.LocationURL = URL1 Then
Set CtrlRange = WebBrowser1.Document.body.createControlRange
CtrlRange.Add WebBrowser1.Document.images(0)
CtrlRange.execCommand ("Copy")
Image1.Picture = Clipboard.GetData
WebBrowser1.Document.getElementById("u").Value = Text1.Text
WebBrowser1.Document.getElementById("p").Value = Text2.Text
WebBrowser1.Document.getElementById("verifycode").Value = UCase(Text3.Text)
WebBrowser1.Document.getElementById("login_button").Click
Timer1.Enabled = False
Timer3.Enabled = True
End If
End Sub
Private Sub Image1_Click()
Label5_Click
End Sub
Private Sub Label5_Click()
Text3.Text = ""
WebBrowser1.Document.getElementById("verifycode").Value = ""
WebBrowser1.Document.getElementById("changeimg_link").Click
End Sub
Private Sub Timer1_Timer()
Dim CtrlRange As Object
Set CtrlRange = WebBrowser1.Document.body.createControlRange
CtrlRange.Add WebBrowser1.Document.images(0)
CtrlRange.execCommand ("Copy")
Image1.Picture = Clipboard.GetData
End Sub
Private Sub Timer2_Timer()
WebBrowser1.Document.getElementById("u").Value = "123456789"
WebBrowser1.Document.getElementById("p").Value = "123456790123"
WebBrowser1.Document.getElementById("login_button").Click
WebBrowser1.Document.getElementById("u").Value = ""
WebBrowser1.Document.getElementById("p").Value = ""
Timer2.Enabled = False
End Sub
Private Sub Timer3_Timer()
If WebBrowser1.LocationURL = URL2 Then
Timer1.Enabled = False
Timer2.Enabled = False
Timer3.Enabled = False
Timer4.Enabled = False
Label1.Visible = False
Label2.Visible = False
Label3.Visible = False
Label4.Visible = False
Label5.Visible = False
Text1.Visible = False
Text2.Visible = False
Text3.Visible = False
Image1.Visible = False
Command1.Visible = False
WebBrowser1.Move 0, 0, Me.ScaleWidth, Me.ScaleHeight
Else
If WebBrowser1.LocationURL = URL1 Then
Label5_Click
Timer1.Enabled = True
Timer3.Enabled = False
End If
End If
End Sub
Private Sub Timer4_Timer()
If Me.Caption = URL1 Then
Timer1.Enabled = True
Timer2.Enabled = True
Timer4.Enabled = False
End If
End Sub
Private Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, URL As Variant)
Me.Caption = WebBrowser1.LocationURL
End Sub
2010年06月10日
'********************webQQ登陆器*****************************
'############################################################
'功能:登陆网页QQ
'作者:裴具才
'QQ:592123987
'时间:2010.6.10
'仅为学习交流使用,请勿非法使用,否则一切后果自负!
'尊重原作者请保留
'###########################################################
'***********************************************************
Dim URL1, URL2 As String
Private Sub Form_Load()
URL1 = "http://ui.ptlogin2.qq.com/cgi-bin/login?style=4&appid=1002101&no_verifyimg=1&s_url=http://web.qq.com/main.shtml?direct&f_url=loginerroralert"
URL2 = "http://web.qq.com/main.shtml?direct"
WebBrowser1.Navigate URL1
Timer1.Enabled = False
Label5.FontUnderline = True
Label5.ForeColor = vbBlue
End Sub
Private Sub Form_Resize()
WebBrowser1.Width = Me.ScaleWidth
WebBrowser1.Height = Me.ScaleHeight
End Sub
Private Sub Command1_Click()
Dim CtrlRange As Object
If WebBrowser1.LocationURL = URL1 Then
Set CtrlRange = WebBrowser1.Document.body.createControlRange
CtrlRange.Add WebBrowser1.Document.images(0)
CtrlRange.execCommand ("Copy")
Image1.Picture = Clipboard.GetData
WebBrowser1.Document.getElementById("u").Value = Text1.Text
WebBrowser1.Document.getElementById("p").Value = Text2.Text
WebBrowser1.Document.getElementById("verifycode").Value = UCase(Text3.Text)
WebBrowser1.Document.getElementById("login_button").Click
Timer1.Enabled = False
Timer3.Enabled = True
End If
End Sub
Private Sub Image1_Click()
Label5_Click
End Sub
Private Sub Label5_Click()
Text3.Text = ""
WebBrowser1.Document.getElementById("verifycode").Value = ""
WebBrowser1.Document.getElementById("changeimg_link").Click
End Sub
Private Sub Timer1_Timer()
Dim CtrlRange As Object
Set CtrlRange = WebBrowser1.Document.body.createControlRange
CtrlRange.Add WebBrowser1.Document.images(0)
CtrlRange.execCommand ("Copy")
Image1.Picture = Clipboard.GetData
End Sub
Private Sub Timer2_Timer()
WebBrowser1.Document.getElementById("u").Value = "123456789"
WebBrowser1.Document.getElementById("p").Value = "123456790123"
WebBrowser1.Document.getElementById("login_button").Click
WebBrowser1.Document.getElementById("u").Value = ""
WebBrowser1.Document.getElementById("p").Value = ""
Timer2.Enabled = False
End Sub
Private Sub Timer3_Timer()
If WebBrowser1.LocationURL = URL2 Then
Timer1.Enabled = False
Timer2.Enabled = False
Timer3.Enabled = False
Timer4.Enabled = False
Label1.Visible = False
Label2.Visible = False
Label3.Visible = False
Label4.Visible = False
Label5.Visible = False
Text1.Visible = False
Text2.Visible = False
Text3.Visible = False
Image1.Visible = False
Command1.Visible = False
WebBrowser1.Move 0, 0, Me.ScaleWidth, Me.ScaleHeight
Else
If WebBrowser1.LocationURL = URL1 Then
Label5_Click
Timer1.Enabled = True
Timer3.Enabled = False
End If
End If
End Sub
Private Sub Timer4_Timer()
If Me.Caption = URL1 Then
Timer1.Enabled = True
Timer2.Enabled = True
Timer4.Enabled = False
End If
End Sub
Private Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, URL As Variant)
Me.Caption = WebBrowser1.LocationURL
End Sub