Advertisement
Guest User

Untitled

a guest
Jun 15th, 2014
293
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
AutoIt 3.68 KB | None | 0 0
  1. Opt("MustDeclareVars", 1)
  2. Opt("WinTitleMatchMode", 2)
  3. Opt("WinWaitDelay", 100)
  4. Opt("TrayIconDebug", 1)
  5.  
  6. Dim $Wpos, $Xkoordinata, $Ykoordinata
  7.  
  8. While 1
  9.     If WinExists("PortableApps.com Platform", "Download Error") Then
  10.         WinActivate("PortableApps.com Platform", "Download Error")
  11.         WinWaitActive("PortableApps.com Platform", "Download Error")
  12.         Sleep(200)
  13.         ControlFocus("PortableApps.com Platform", "Download Error", "Button1")
  14.         ControlClick("PortableApps.com Platform", "Download Error", "Button1")
  15.     EndIf
  16.     If WinExists("PortableApps.com Platform", "is not valid and can not be installed") Then
  17.         Sleep(600000)
  18.         WinActivate("PortableApps.com Platform", "is not valid and can not be installed")
  19.         WinWaitActive("PortableApps.com Platform", "is not valid and can not be installed")
  20.         Sleep(200)
  21.         ControlFocus("PortableApps.com Platform", "is not valid and can not be installed", "Button1")
  22.         ControlClick("PortableApps.com Platform", "is not valid and can not be installed", "Button1")
  23.     EndIf
  24.     If WinExists("PortableApps.com Installer", "Please review the license") Then
  25.         WinActivate("PortableApps.com Installer", "Please review the license")
  26.         WinWaitActive("PortableApps.com Installer", "Please review the license")
  27.         Sleep(200)
  28.         ControlFocus("PortableApps.com Installer", "Please review the license", "Button2")
  29.         ControlClick("PortableApps.com Installer", "Please review the license", "Button2")
  30.     EndIf
  31.     If WinExists("PortableApps.com Installer", "Click Next to continue") Then
  32.         WinActivate("PortableApps.com Installer", "Click Next to continue")
  33.         WinWaitActive("PortableApps.com Installer", "Click Next to continue")
  34.         Sleep(200)
  35.         ControlFocus("PortableApps.com Installer", "Click Next to continue", "Button2")
  36.         ControlClick("PortableApps.com Installer", "Click Next to continue", "Button2")
  37.         For $i = 1 To 5 Step 1
  38.             If WinExists("PortableApps.com Installer ", "Choose Components") Or WinExists("PortableApps.com Installer ", "Please review the license") Then
  39.                 Select
  40.                     Case WinExists("PortableApps.com Installer ", "Choose Components")
  41.                         WinActivate("PortableApps.com Installer ", "Choose Components")
  42.                         WinWaitActive("PortableApps.com Installer ", "Choose Components")
  43.                         $Wpos = WinGetPos("PortableApps.com Installer ", "Choose Components")
  44.                     Case WinExists("PortableApps.com Installer ", "Please review the license")
  45.                         WinActivate("PortableApps.com Installer ", "Please review the license")
  46.                         WinWaitActive("PortableApps.com Installer ", "Please review the license")
  47.                         $Wpos = WinGetPos("PortableApps.com Installer ", "Please review the license")
  48.                 EndSelect
  49.                 $Xkoordinata = $Wpos[0] + 366
  50.                 $Ykoordinata = $Wpos[1] + 367
  51.                 MouseMove($Xkoordinata, $Ykoordinata)
  52.                 MouseClick("left")
  53.                 ExitLoop
  54.             EndIf
  55.             If WinExists("PortableApps.com Installer ", "Choose Install Location") Then
  56.                 ExitLoop
  57.             EndIf
  58.             Sleep(1000)
  59.         Next
  60.         WinWait("PortableApps.com Installer ", "Choose Install Location")
  61.         WinActivate("PortableApps.com Installer ", "Choose Install Location")
  62.         WinWaitActive("PortableApps.com Installer ", "Choose Install Location")
  63.         Sleep(200)
  64.         ControlFocus("PortableApps.com Installer ", "Choose Install Location", "Button2")
  65.         ControlClick("PortableApps.com Installer ", "Choose Install Location", "Button2")
  66.         WinWait("PortableApps.com Installer ", "Click Finish to close")
  67.         WinActivate("PortableApps.com Installer ", "Click Finish to close")
  68.         WinWaitActive("PortableApps.com Installer ", "Click Finish to close")
  69.         Sleep(200)
  70.         ControlFocus("PortableApps.com Installer ", "Click Finish to close", "Button2")
  71.         ControlClick("PortableApps.com Installer ", "Click Finish to close", "Button2")
  72.     EndIf
  73.     Sleep(1000)
  74. WEnd
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement