pjotterke Posted February 22, 2007 Share Posted February 22, 2007 Hi i need your help with the following... i am making a script for errors. so if there is an error it have to go back i do the same thing again till it works... so i begin with scripting and made this If WinActive ("Session Error", "Unrecognised panel received unexpextedly during logon" ) Then Sleep (500) Send ("{enter}") WinWaitActive ("JBA System 21") Exit Else EndIf but how can i make it so my script go's back to the steps before this.... thanks!... Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted February 22, 2007 Moderators Share Posted February 22, 2007 (edited) Wrap it in a While/WEnd loop or:Do Sleep(10) Until WinActive ("Session Error", "Unrecognised panel received unexpextedly during logon" ) Sleep (500) Send ("{enter}") WinWaitActive ("JBA System 21") ExitoÝ÷ ØGb´êÚºÚ"µÍÚ[ØZ]XÝ]J ][ÝÔÙÜÚ[ÛÜ][ÝË ][ÝÕ[XÛÙÛÙY[[XÙZ]Y[^^YH[ÈÙÛÛ][ÝÈ BÛY L BÙ[ ][ÝÞÙ[I][ÝÊBÚ[ØZ]XÝ]H ][ÝÒHÞÝ[HI][ÝÊB^] Edited February 22, 2007 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
pjotterke Posted February 22, 2007 Author Share Posted February 22, 2007 sleep (2000) While Send ("!A") send ("P") Send ("{enter}") sleep (1000) If WinActive ("Session Error", "Unrecognised panel received unexpextedly during logon" ) Then Sleep (500) Send ("{enter}") Sleep (1000) Send ("{F12}") Sleep (500) Exit Else EndIf WEnd like this? but it don't go out the loop now Link to comment Share on other sites More sharing options...
pjotterke Posted February 22, 2007 Author Share Posted February 22, 2007 K thanks Smoke i have the salution... While Send ("!A") send ("P") Send ("{enter}") sleep (1000) If WinActive ("Session Error", "Unrecognised panel received unexpextedly during logon" ) Then Sleep (500) Send ("{enter}") else ExitLoop EndIf WEnd thanks again Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now