rnj Posted May 1, 2006 Share Posted May 1, 2006 Hi, I am trying to do a instal of NERO and BURN RIGHTS remotely on multiple workstations. I have written the following script which does the install until NERO OEM. When it goes to install Burn rights, there is a conflict, as the software reports that "instance of installation process is already running". I checked task manager and found that NERO setup.exe is still running. So I added the process close function. But somehow it does not work...Both these installs have a common name (setup.exe)..as you can see..How do I run one install, finish it and then run the other one...The softies are stored on network server. $p=Run("\\networkpath\Nero 6 OEM\Nero OEM\Setup.exe") WinWaitActive("Nero OEM Installation Wizard") Send("{Enter}") Send("{TAB}") Send("{UP}") Send("{TAB}") Send("{TAB}") Send("{SPACE}") Send("{ENTER}") Send("{ENTER}") Send("{ENTER}") If $p Then ProcessClose($p) MsgBox(8192, "Please wait...", "Burn Rights will install in 15 seconds", 15) Run("\\network path\Nero 6 OEM\Nero BurnRights\setup.exe") Send("{ENTER}") Send("{ENTER}") Send("{DOWN}") Send("{TAB}") Send("{ENTER}") Exit Any help is much appreciated. Cheers, RnJ [font="Franklin Gothic Medium"]RnJ[/font][font="Franklin Gothic Medium"]Script: AutoIT v3.1.1.124 (beta)[/font][font="Franklin Gothic Medium"]OS: Windows XP/2000[/font] Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted May 1, 2006 Share Posted May 1, 2006 use autoits window info to get control IDs so you can do a controlclick Link to comment Share on other sites More sharing options...
herewasplato Posted May 1, 2006 Share Posted May 1, 2006 (edited) Edit: Welcome to the forums.... If the Nero setup process exits when you run it manually, then it should do so when the script runs it. Run("\\networkpath\Nero 6 OEM\Nero OEM\Setup.exe") WinWaitActive("Nero OEM Installation Wizard") Send("{Enter}") Send("{TAB}") Send("{UP}") Send("{TAB}") Send("{TAB}") Send("{SPACE}") Send("{ENTER}") Send("{ENTER}") Send("{ENTER}") Do Sleep(99) Until Not ProcessExits("Setup.exe") MsgBox(8192, "Please wait...", "Burn Rights will install in 15 seconds", 15) Run("\\network path\Nero 6 OEM\Nero BurnRights\setup.exe") Send("{ENTER}") Send("{ENTER}") Send("{DOWN}") Send("{TAB}") Send("{ENTER}") Exit Edited May 1, 2006 by herewasplato [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
MHz Posted May 1, 2006 Share Posted May 1, 2006 (edited) If $p Then ProcessClose($p)Replace with: ProcessWaitClose($p) Edited May 1, 2006 by MHz Link to comment Share on other sites More sharing options...
herewasplato Posted May 1, 2006 Share Posted May 1, 2006 ProcessWaitClose($p) Doh! [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
rnj Posted May 1, 2006 Author Share Posted May 1, 2006 use autoits window info to get control IDs so you can do a controlclickI do not quite get it..what is control click??? I have opened the auto it window...It just shows whatever activity I do on the comp.. [font="Franklin Gothic Medium"]RnJ[/font][font="Franklin Gothic Medium"]Script: AutoIT v3.1.1.124 (beta)[/font][font="Franklin Gothic Medium"]OS: Windows XP/2000[/font] Link to comment Share on other sites More sharing options...
herewasplato Posted May 1, 2006 Share Posted May 1, 2006 ...what is control click???...Look at the calc script at the bottom of this post http://www.autoitscript.com/forum/index.ph...ndpost&p=178475ControlClick is a better way to "click" buttons and things... [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
exodius Posted May 1, 2006 Share Posted May 1, 2006 (edited) I do not quite get it..what is control click??? I have opened the auto it window...It just shows whatever activity I do on the comp.. Every button that you click is a "control". Using the AutoIt Window Info tool, you can get the names of the controls but putting your mouse over them. Then, by doing a ControlClick, AutoIt can tell the window to click that particular button which can happen regardless of whether anything else is going on.(Your Send commands could get thrown off if someone clicks on another window for instance.) It's also a good idea to put checks in your script so you're making sure that you get to the next window before you continue on. What if your script was run on a slightly slower computer so it took it a little longer to get to the next window and the number of times you Send ( "Enter" ) was thrown off? This is usually a good methodology to follow: WinWait ("WinName") WinActivate ("WinName") WinWaitActive ("WinName") ControlClick ("WinName", "", "Control" ) Edited May 1, 2006 by exodius Link to comment Share on other sites More sharing options...
MHz Posted May 1, 2006 Share Posted May 1, 2006 (edited) Perhaps alittle complex fro a beginner, but this script shows the real use of ControlClick to install PrimoPDF.Edit:Control* functions do not require active windows ! Edited May 1, 2006 by MHz Link to comment Share on other sites More sharing options...
rnj Posted May 1, 2006 Author Share Posted May 1, 2006 I have pasted part of my script. The control clicks work fine, until the last step. The finish screen the control click do not work. What is going wrong? If FileExists("C:\Program Files\Ahead") Then MsgBox(0, "", "Previous version of NERO found, Deleting previous version...", 5) DirRemove("C:\Program Files\Ahead", 1) Sleep(5000) MsgBox(0,"", "Installing NERO OEM...",3) $pid=Run("\\Network path\CD Burn Software\Nero 6 OEM\Nero OEM\Setup.exe") WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1042) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1047) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1042) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","Customer information.",1042) WinWait("Nero OEM Installation Wizard","Nero OEM installation in progress") WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","Please click "Finish" to exit the Installation Wizard.",1040) ProcessWaitClose($pid) Cheers, RnJ [font="Franklin Gothic Medium"]RnJ[/font][font="Franklin Gothic Medium"]Script: AutoIT v3.1.1.124 (beta)[/font][font="Franklin Gothic Medium"]OS: Windows XP/2000[/font] Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted May 1, 2006 Share Posted May 1, 2006 cuz ur finish has "" around it if its supposed to be like that ControlClick("Nero OEM Installation Wizard","Please click" & '"' & "Finish" & '"' & "to exit the Installation Wizard.",1040) hahah idk if itll work Link to comment Share on other sites More sharing options...
rnj Posted May 1, 2006 Author Share Posted May 1, 2006 MsgBox(0, "", "Previous version of NERO found, Deleting previous version...", 5) DirRemove("C:\Program Files\Ahead", 1) Sleep(5000) MsgBox(0,"", "Installing NERO OEM...",3) $pid=Run("\\netowork path\CD Burn Software\Nero 6 OEM\Nero OEM\Setup.exe") WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1042) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1047) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1042) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","Customer information.",1042) WinWaitActive("Nero OEM Installation Wizard","Nero OEM installation in progress") WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","Finish" & "The Wizard has completed the installation successfully." & "Please click" & '"' & "Finish" & '"' & "to exit the Installation Wizard.",1040) ProcessWaitClose($pid) Kinda crazy, but after it passes the Nero OEM installation in progress screen, the screen just stops at the Finish screen. Nothing happens...Must be something in the script or winwait functions... [font="Franklin Gothic Medium"]RnJ[/font][font="Franklin Gothic Medium"]Script: AutoIT v3.1.1.124 (beta)[/font][font="Franklin Gothic Medium"]OS: Windows XP/2000[/font] Link to comment Share on other sites More sharing options...
MHz Posted May 1, 2006 Share Posted May 1, 2006 WinWaitActive("Nero OEM Installation Wizard","Nero OEM installation in progress").........ControlClick("Nero OEM Installation Wizard","Finish" & "The Wizard has completed the installation successfully." & "Please click" & '"' & "Finish" & '"' & "to exit the Installation Wizard.",1040)ProcessWaitClose($pid)The WinWaitActive looks unrequired. Looks like the ControlClick has multilines in the text parameter?Use either:FinishorThe Wizard has completed the installation successfullyorPlease click Link to comment Share on other sites More sharing options...
exodius Posted May 1, 2006 Share Posted May 1, 2006 Maybe try: ControlClick("Nero OEM Installation Wizard", "", "Finish" ) or ControlClick("Nero OEM Installation Wizard", "", "&Finish" ) Link to comment Share on other sites More sharing options...
rnj Posted May 1, 2006 Author Share Posted May 1, 2006 None of the above suggested methods work...This is really confusing..I am pretty sure it is a simple mistake ..but where...??? [font="Franklin Gothic Medium"]RnJ[/font][font="Franklin Gothic Medium"]Script: AutoIT v3.1.1.124 (beta)[/font][font="Franklin Gothic Medium"]OS: Windows XP/2000[/font] Link to comment Share on other sites More sharing options...
rnj Posted May 1, 2006 Author Share Posted May 1, 2006 When I use the following timeout, it works fine...But using the timeout defeats the whole purpose of control click $pid=Run("\\network path\CD Images\CD Burn Software\Nero 6 OEM\Nero OEM\Setup.exe") WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1042) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1047) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","",1042) WinWait("Nero OEM Installation Wizard") ControlClick("Nero OEM Installation Wizard","Customer information.",1042) WinWait("Nero OEM Installation Wizard","Nero OEM installation in progress") WinWait("Nero OEM Installation Wizard","The Wizard has completed the installation successfully",180) ControlClick("Nero OEM Installation Wizard","",1040) ProcessWaitClose($pid) [font="Franklin Gothic Medium"]RnJ[/font][font="Franklin Gothic Medium"]Script: AutoIT v3.1.1.124 (beta)[/font][font="Franklin Gothic Medium"]OS: Windows XP/2000[/font] 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