Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Local $filename
- If $CmdLine[0] = 1 Then
- $filename = $CmdLine[1]
- else
- MsgBox(0, "ERROR", "File not found")
- Exit
- EndIf
- ; Wait for 5 seconds.
- Sleep(5000)
- ; Wait 10 seconds for the Upload window to appear
- Local $hWnd=WinWait("[CLASS:#32770]","",10)
- ; Set input focus to the edit control of Upload window using the handle returned by WinWait
- ControlFocus($hWnd,"","Edit1")
- ; Wait for 2 seconds.
- Sleep(2000)
- ; Set the File name text on the Edit field
- ControlSetText($hWnd, "", "Edit1", $filename)
- Sleep(2000)
- ; Click on the Open button
- ControlClick($hWnd, "","Button1");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement