Jump to content

Hiding Setup Windows


Recommended Posts

Hi, I have made a script which installs avg 8.5 for me, it works perfectly but i would like to hide the setup windows, so i cant see it clicking next, next for example. Here is the script if you get what i mean. I have already searched the help files but cant find what i need or maby im looking in the wrong place.

#NoTrayIcon
;AVG Setup ------------------------------

Run("C:\Documents and Settings\Aaron\Desktop\avg.exe")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Accept")
Send("{LEFT}")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Accept")
Send("{TAB}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")

;checks system at this point

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{ENTER}")

;no toolbar

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{TAB}")
Send("{TAB}")
Send("{SPACE}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Finish")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&OK")
Send("{ENTER}")

;AVG setup finished ----------------------

;AVG Config ------------------------------

WinWait("AVG First Run Wizard", "Next >")
Send("{ENTER}")

;Disable Daily Scanning ---------------------

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{TAB}")
Send("{TAB}")
Send("{SPACE}")
Send("{ENTER}")
Send("{TAB}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")
;finish

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{ENTER}")

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{ENTER}")

;at this point avg will auto check for updates

WinWaitActive("AVG First Run Wizard", "Update was finished successfully.")
Send("{TAB}")
Send("{ENTER}")

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{ENTER}")

WinWaitActive("AVG First Run Wizard", "Finish")
Send("{ENTER}")

MsgBox(0, "Setup", "Install Completed Successfully", 5)

Thanks

Link to comment
Share on other sites

Hi, I have made a script which installs avg 8.5 for me, it works perfectly but i would like to hide the setup windows, so i cant see it clicking next, next for example. Here is the script if you get what i mean. I have already searched the help files but cant find what i need or maby im looking in the wrong place.

#NoTrayIcon
;AVG Setup ------------------------------

Run("C:\Documents and Settings\Aaron\Desktop\avg.exe")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Accept")
Send("{LEFT}")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Accept")
Send("{TAB}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")

;checks system at this point

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{ENTER}")

;no toolbar

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Next >")
Send("{TAB}")
Send("{TAB}")
Send("{SPACE}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&Finish")
Send("{ENTER}")

WinWaitActive("AVG Free 8.5 build 278 (3/2/2009)", "&OK")
Send("{ENTER}")

;AVG setup finished ----------------------

;AVG Config ------------------------------

WinWait("AVG First Run Wizard", "Next >")
Send("{ENTER}")

;Disable Daily Scanning ---------------------

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{TAB}")
Send("{TAB}")
Send("{SPACE}")
Send("{ENTER}")
Send("{TAB}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")
;finish

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{ENTER}")

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{ENTER}")

;at this point avg will auto check for updates

WinWaitActive("AVG First Run Wizard", "Update was finished successfully.")
Send("{TAB}")
Send("{ENTER}")

WinWaitActive("AVG First Run Wizard", "Next >")
Send("{ENTER}")

WinWaitActive("AVG First Run Wizard", "Finish")
Send("{ENTER}")

MsgBox(0, "Setup", "Install Completed Successfully", 5)

Thanks

Hi,

Function Send is only working with active windows. You have to recode.

Have a look at help file function ControlSend and ControlClick. They are even working with hided windows.

To get the controlID's use AutoIT Window Info Tool.

;-))

Stefan

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...