Sign in to follow this  
Followers 0
pjotterke

Help me with small problem

4 posts in this topic

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!...

Share this post


Link to post
Share on other sites



#2 ·  Posted (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 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.

Share this post


Link to post
Share on other sites

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

Share this post


Link to post
Share on other sites

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

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  
Followers 0