SimonMag Posted July 3, 2009 Share Posted July 3, 2009 I am trying to write a script that will launch a setup.exe and then 'click' the appropriate buttons when it needs to. So far I have a very simple script that is working, using the Sleep command. The problem I have is if the user is on the end of a slow link, the time would not be long enough. How do i go about looking for the Title or information contained in the installation screens? This is what I have so far... CODERun ('\\fs_zdm\VOL1\Applications\Install Apps\zesClient\setup.exe /V"STUNINSTALL=1 STUIP=\"zesuninstall\" STRBR=ReallySupress /L*v c:\zeslog.txt' , "") Sleep(5000) Send("{ENTER}") Sleep(5000) Send("{ENTER}") Thanks Simon. Link to comment Share on other sites More sharing options...
somdcomputerguy Posted July 3, 2009 Share Posted July 3, 2009 WinWait and/or WinActive? - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change. Link to comment Share on other sites More sharing options...
Drew Posted July 3, 2009 Share Posted July 3, 2009 WinGetTitle WinGetHandle WinWait WinActive WinActivate WinExists All in the helpfile. You can view many other window management functions in the help file as well. If you can manage a bit more code we can help you alot alot more. Link to comment Share on other sites More sharing options...
SimonMag Posted July 6, 2009 Author Share Posted July 6, 2009 Thanks for the pointers, I did manage to find a AutoIT recorder and that managed to give me the commands I needed. This is what I ended up with, seems to do what I need it to: Opt("WinWaitDelay",100) Opt("WinTitleMatchMode",4) Opt("WinDetectHiddenText",1) Run('\\fs_zdm\VOL1\Applications\Install Apps\zesClient\setup.exe /V"STUNINSTALL=1 STUIP=\"zesuninstall\" STRBR=ReallySupress"') WinWait("Choose Setup Language","") If Not WinActive("Choose Setup Language","") Then WinActivate("Choose Setup Language","") WinWaitActive("Choose Setup Language","") Send("{ENTER}") WinWait("ZENworks Security Client - InstallShield Wizard","") If Not WinActive("ZENworks Security Client - InstallShield Wizard","") Then WinActivate("ZENworks Security Client - InstallShield Wizard","") WinWaitActive("ZENworks Security Client - InstallShield Wizard","") Send("{ENTER}") Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now