Jump to content
EddieK

Wait until installation is complete - Press Finish Button

Recommended Posts

EddieK

Hi all,

first sorry for my english. I want my script to press the finish button when the installation progress has finished (without sleep command). Background is to install the software on different machines. One is faster then  the other.

Run("NwSapSetup.exe")
sleep(500)
WinWaitActive("SAP Front-End Installer")
ControlClick("SAP Front-End Installer", "&Weiter >", "Button1")
sleep(500)
WinWaitActive("SAP Front-End Installer")
send("{SPACE}")
sleep(500)
ControlClick("SAP Front-End Installer", "&Weiter >", "Button1")
sleep(500)
WinWaitActive("SAP Front-End Installer")
sleep(500)
ControlClick("SAP Front-End Installer", "&Weiter >", "Button1")
WinWait("SAP Front-End Installer")
sleep(120000)
ControlClick("SAP Front-End Installer", "Beenden", "Button1")

 

Could you please help?

Thanks

Share this post


Link to post
Share on other sites
water

Welcome to AutoIt and the forum!

Couldn't you use the /silent command line switch so you do not need to automate the GUI?

Bei Bedarf kannst Du die Frage auch auf Deutsch stellen ;)


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
water

Here is the needed link to the SAP documentation.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
EddieK

Hi water,

thanks for your response. I'll try the command line switch.

But is it possible to work without sleep command?

Share this post


Link to post
Share on other sites
water

Sure. Sleep is not needed at all. Each line is only executed when the previous line has ended processing.
What I would suggest is to check for errors after running a function.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
TheDcoder

@EddieK RunWait can do the trick ;)

 

Just noticed that you want to click the finish button, there is an alternative, Use RunWait like this:

RunWait("NwSapSetup.exe /silent") ; This will install the program in the background (waits until it finishes intalling)

 

TD :D

Edited by TheDcoder

AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Spoiler

My contributions to the AutoIt Community

If I have hurt or offended you in anyway, Please accept my apologies, I never (regardless of the situation) mean to do that to anybody!!!

3fHNZJ.gif

PLEASE JOIN ##AutoIt AND HELP THE IRC AUTOIT COMMUNITY!

Share this post


Link to post
Share on other sites
EddieK
RunWait("NwSapSetup.exe /silent /Product="SAPGUI710")

This works :)  Thank you all.

Share this post


Link to post
Share on other sites
TheDcoder

@EddieK My pleasure :)


AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Spoiler

My contributions to the AutoIt Community

If I have hurt or offended you in anyway, Please accept my apologies, I never (regardless of the situation) mean to do that to anybody!!!

3fHNZJ.gif

PLEASE JOIN ##AutoIt AND HELP THE IRC AUTOIT COMMUNITY!

Share this post


Link to post
Share on other sites
water

Just noticed that you want to click the finish button, there is an alternative, Use RunWait like this:

RunWait("NwSapSetup.exe /silent") ; This will install the program in the background (waits until it finishes intalling)

TheCoder,

by using the "/silent" switch there will be no GUI and hence no need to click the finish button. And "/silent" has already been proposed in post #3 ;)


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
TheDcoder

@water I wanted to show him the usage of RunWait & /silent switch, TD :)

 

P.S I am not TheCoder :P

Edited by TheDcoder

AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Spoiler

My contributions to the AutoIt Community

If I have hurt or offended you in anyway, Please accept my apologies, I never (regardless of the situation) mean to do that to anybody!!!

3fHNZJ.gif

PLEASE JOIN ##AutoIt AND HELP THE IRC AUTOIT COMMUNITY!

Share this post


Link to post
Share on other sites
TheDcoder

Ok, sorry if made a mistake, I am still learning :P. Appreciated for guiding me...

 

TD :)


AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Spoiler

My contributions to the AutoIt Community

If I have hurt or offended you in anyway, Please accept my apologies, I never (regardless of the situation) mean to do that to anybody!!!

3fHNZJ.gif

PLEASE JOIN ##AutoIt AND HELP THE IRC AUTOIT COMMUNITY!

Share this post


Link to post
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

×