MYK

AutoIT script opens the Installer application in minimized state when system is locked. Need to launch as active

6 posts in this topic

#1 ·  Posted (edited)

I am using Autoit to install an application.

When I execute the script while system is not locked the installer application launches as maximized and but when when system is locked it get's minimized due to which the scripts don't run and wait for it to get maximised. Can some one help please? I have checked many solutions online but not very successfull. Below is my code

#include <Array.au3>
#include <WinAPIShPath.au3>

$CmdLine[1];
Run($CmdLine[1])

Sleep(2000)
WinWait("Installer Application","&Next")

ControlClick("Installer Application","&Next","[CLASS:Button; INSTANCE:2]")

Sleep(2000)
WinWait("Installer Application","Yes")

 ...... The code goes on. The issue is only at the start, After the Run() command the application is minimized and not active due to which the script pauses until I manually mmaximize it. Please help

Edited by MYK

Share this post


Link to post
Share on other sites



Welcome to AutoIt and the forum!
Can you tell us which program you try to install? Most installers provide a silent installation command line switch. So there would be no need to automate the GUI.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2017-04-18 - Version 1.4.8.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2017-02-27 - Version 1.3.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites

@Water .... It's similar to any installer like your games installation or a photoshop installation ... Basically a setup.exe .... Could you please share a sample silent installer please?

Share this post


Link to post
Share on other sites

It depends on the tool that is used to create the installation exe.
Most of the time I ask Google for "xxxx silent installation command line switch" where "xxxx" is the name of the product.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2017-04-18 - Version 1.4.8.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2017-02-27 - Version 1.3.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version 0.4.0.0) - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version 0.0.5.0) - Download - General Help & Support

Tutorials:
ADO - Wiki

 

Share this post


Link to post
Share on other sites

Could you please share a sample silent installer please?

We certainly can, if you would share the product name. As has been pointed out, every application is different.


√-1 2^3 ∑ π, and it was delicious!

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