SAVE&CLICK

Public Class Form1
Private Declare Auto Function FindWindowEx Lib “user32” (ByVal parentHandle As Integer, _
ByVal childAfter As Integer, _
ByVal lclassName As String, _
ByVal windowTitle As String) As Integer
Private Declare Function SetForegroundWindow Lib “user32” (ByVal hwnd As IntPtr) As Long
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Dim handle As Integer = FindWindowEx(0, 0, Nothing, “文件下载”)
While True
‘MsgBox(handle)
If handle <> 0 Then
SetForegroundWindow(handle)
SendKeys.Send(“{S}”)
‘SendKeys.Send(“{LEFT}”)
‘Delay(500)
‘SendKeys.Send(“{ENTER}”)
‘Delay(500)
End If
Delay(500)
handle = FindWindowEx(0, 0, Nothing, “文件下载”)
End While
End Sub

End Class

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *