Jump to content

Recommended Posts

Posted

You need to loop the script so it doesn't exit while using adlib.

AdlibEnable("myadlib")

While 1
WEnd

Exit

Func myadlib()
    If WinActive("Error") Then
    Else
        msgbox(0,"","")
    EndIf
EndFunc
Posted

I'd fire a sleep in there so you don't kill the CPU

AdlibEnable("myadlib")

While 1
sleep(2000)
WEnd

Exit

Func myadlib()
    If WinActive("Error") Then
    Else
        msgbox(0,"","")
    EndIf
EndFunc
Posted

It was just an example. Sleep is always great in a loop. I almost never go without a sleep. If I need a tight loop, but still don't want to kill the CPU, I use Monoceres' script here.

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
  • Recently Browsing   0 members

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