Jump to content

WinWait don't work if title change


Recommended Posts

Hi all! :)

I'm trying to automate a program installation with AutoIt (version 3.3.0.0).

During installation screens, I do something like that:

;******START*****

WinWait("WinZip", "Next >")

WinActivate("WinZip", "Next >")

Send("{ENTER}")

;

;second screen

WinWait("Licence")

WinActivate("Licence")

Send("{ENTER}")

;...

;******END*****

The execution of my script stops at the second WinWait call! :)

With some tests, I've discover that while the installation window's title CHANGE (from WinZip to Licence), in AutoIt keep the same title (WinZip).

What's wrong?

THX in advance!

Monica

Link to comment
Share on other sites

http://dundats.mvps.org/help/html/tutorials/winzip/winzip.htm

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

http://dundats.mvps.org/help/html/tutorials/winzip/winzip.htm

Hi GeoSoft!

Thx for your reply... and for your link!

but WinZip was only an example... :)

The program is LogMeIn. Now I try again with the WinWaitActive funcion, as your winzip tutorial use, but fail!

AutoIt remain waiting for windows appear or activate; I must close it from a tray icon.

For better understand this problem, I've tryed this code:

;***START***

$wh = WinGetHandle("LogMeIn")

While(1)

$prova = WinGetTitle($wh)

MsgBox(0, "Window title is:", $prova)

sleep(2000)

WEnd

;***END***

When the 1st screen is shown, the MsgBox text is (correctly) "LogMeIn". But when the 2nd screen appear, the MsgBox text is "0". If so, I think that the 1st window is closed from the installation program, and another is created. But in this case, funcion WinWait or WinWaitActive should work fine... or not? Help! :)

Link to comment
Share on other sites

Have you use the "Autoit WIndows Info" ?

First you install manually your software seeing each window titles and controls of windows.

Then you can automate the install.

And you can test in the window already exist with the function WinExists ()

Edited by jerem488

Qui ose gagneWho Dares Win[left]CyberExploit[/left]

Link to comment
Share on other sites

Which LogMeIn product is it?

...maybe I can replicate your issue.

http://www.logmein.com

But to download the installation file, you must register... so... if you want, I'll send it to you by email, thanks!

jerem488

Yes I do exactly in this way... In AutoIt Window Info the title change!

Look this:

Posted Image

It's strange, only this installation program seems not work with AutoIt!

Link to comment
Share on other sites

Opt("WinTitleMatchMode", 2) ?

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)



460px-Thief-4-temp-banner.jpg
There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

 
Link to comment
Share on other sites

Opt("WinTitleMatchMode", 2) ?

Bingo! :)

I don't know why, but now my script works fine. Evidently, there is a character not visible after the start of real title window.

Thx a lot to all, this forum is great and very helpful for me.

Monica

Link to comment
Share on other sites

to explain so that you dont confuse others :)

I don't know why, but now my script works fine. Evidently, there is a character not visible after the start of real title window.

there probably arent any not visible chars in that wintitle

Opt("WinTitleMatchMode", 1)

1 = Match the title from the start (default)

2 = Match any substring in the title ;<== this mean any part of the title so that you dont need to know it from the start like in default option or to know exact win name like in third option, easy explanation its something like StringinStr command (any part of window name) :)

3 = Exact title match

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)



460px-Thief-4-temp-banner.jpg
There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

 
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...