Jump to content
Sign in to follow this  

Help with a Script

Recommended Posts

;------------------------------------Installation Begins-------------------------------------;
WinWaitActive("XYZ Server Software", "Start Installation")
ControlClick("XYZ Server Software", "Start Installation", "[CLASS:Button; TEXT:&Install >]")
If NOT(WinWait("Error", "ignore",4)=0) Then
   ; A window pops up that requires user input... leaving that window for now
   WinActivate("Error", "ignore")
   WinWaitActive("Error", "ignore")
   ControlClick("Error", "ignore", "[CLASS:Button; TEXT:&Ignore >]")
This is part of the script trying to use for an installation. I added the second part to handle the error popup that comes up for subsequent installation(Not with first time installation).
The error pop heading is Error and it has a message which contains word ignore , so I added ignore.
And it gives three options to choose abort , try again and ignore.
So, I want to select ignore if this comes up. I am unable to get this working, Any suggestions?

Share this post

Link to post
Share on other sites

Hi padmag, what is the software you're trying to install? If it supports (as most apps do) some form of command line options, you may be able to save yourself the grief of trying to manipulate the GUI.

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

How to get your question answered on this forum!

Share this post

Link to post
Share on other sites

Its an exe , It used to work earlier but it was not handling the error pop that comes up in between now. I am trying to understand how to handle this ,& I am new to Autoit :-(

Edited by padmag

Share this post

Link to post
Share on other sites

Back in the day (get off my lawn :) ), there didn't used to be a "ControlClick".  It used to be that one had to engineer a series of tabs and etcetera to navigate normal window focus to the place to click and then send keystrokes.

Absolutely, unquestionably, "ControlClick" is more reliable.  But it may very well be that you can solve this problem, this time, by looking at which control starts with focus, how many tabs you need to send until you are on the correct button, and then send a space character to select the button.

EDIT: Or alternatively, if the ignore button has an accelerator, you might just send that.  For example, if it looks like "Ignore", try Send("^i") and Send("!i").

Again, this is NOT as reliable as "ControlClick".  But it may be the way you need to go in this instance.

Edited by mrider

How's my riding? Dial 1-800-Wait-There

Trying to use a computer with McAfee installed is like trying to read a book at a rock concert.

Share this post

Link to post
Share on other sites



Its an exe

Really? How unusual! :o

Seriously, what is it that you are installing? The more detail you give us, the better the help you are likely get. ;)


Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:


ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area


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
Sign in to follow this