Jump to content

Winwait don´t breack the execution of the script.


saulik
 Share

Recommended Posts

Set the timer value of function WinWait and check the returned value. If it is 0 then the timeout expired = the window never appeared.

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

Water,

Thank's a lot, but what' wrong whit my script below?

I want just wait until the window appear and of the script continue for execute:

Send("{TAB}")

MsgBox(4096, "UPDATE", "Você está logado no ambiente INVESTPREV", 2)

My version is: 1.79

Variables

Dim $r

Dim $e

WinActivate("[CLASS:Tform1]", "")

ControlClick("Form1", "", "[CLASS:TButton; TEXT:Button1; INSTANCE:1]")

$e = 0

If @error = 0 Then

$r = WinWait("[Form2]", "", 10)

If $r = 1 Then

;WinActivate("[CLASS:Tform2]", "")

Send("{TAB}")

MsgBox(4096, "UPDATE", "Você está logado no ambiente INVESTPREV", 2)

Else

$e = 1

EndIf

EndIf

Link to comment
Share on other sites

  • Moderators

You really need to choose one of these two topics and stick to it. This double posting only makes it harder for people to assist you.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

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