Jump to content
Sign in to follow this  
keenharlequin

Running a script in a loop

Recommended Posts

keenharlequin

This is a complete newbie question, but I didn't find the answer in the FAQs, so here goes...

I have a fairly complex mostly-automated build task that has an annoying message box that comes up several times during the build that I need to send a couple keystrokes to to make it go away. The message box comes up several times, so I need the script to run every time it comes up.

I first tried simply this:

WinWaitActive("Resolve Library Conflict")
Send("{DOWN}{ENTER}")oÝ÷ Ù8Z¶;¬¶È¦¦Ù÷öÜ(®DázÇ+ijëu©Ýv'gßÛ]¡©ò¶§^Ø^ë,j£ë©!ø§jYr¶¸vØb±«­¢+Ù±¥¹± ÅÕ½Ðí±Í¡±¥ÅÕ½Ðì¤ì)]¡¥±Ä)]¹()Õ¹±Í¡±¥ ¤(%%]¥¹Ñ¥Ù ÅÕ½ÐíIͽ±Ù1¥ÉÉä
½¹±¥ÐÅÕ½Ðì¤Q¡¸($%M¹ ÅÕ½Ðíí=]9õí9QIôÅÕ½Ðì¤(%¹%)¹Õ¹

This works, but eats up a lot of CPU (~50%).

What am I missing? Is there an obvious easier solution?

Thanks!

Share this post


Link to post
Share on other sites
Nahuel

Or...

While 1
    Sleep(100)
    If WinExists("Resolve Library Conflict") Then
        WinActivate("Resolve Library Conflict")
        Send("{DOWN}{ENTER}")
    EndIf
Wend

Share this post


Link to post
Share on other sites
keenharlequin
While WinWaitActive("Resolve Library Conflict", 5)
    Send('{DOWN}{ENTER}')
    Sleep(50)
WEndoÝ÷ Ûú®¢×©äÊ·Ý8b±©f¢Ëp¢¹tay-êÞßÛìm­¦«éاZ)Öj+@rدzØ^µìm¡ûa{§vë-­é¨½çmëbê.µªàºg§¶ØhºZØ­Âä²X¤y§!j¹v¥r^jëh×6While WinWaitActive("Resolve Library Conflict")
    Send('{DOWN}{ENTER}')
    Sleep(50)
WEnd

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  

×