Jump to content

Recommended Posts

  • Solution
Posted

Maybe because you have 2 nested loops: While 1 ... Do .. Until ... Wend

When you exit out of the do loop, it loops forever again in the while loop.

Here is a solution:

#include <Misc.au3>

Local $hDLL = DllOpen("user32.dll")
$hTime = TimerInit()

Do
    If TimerDiff($hTime) > 2000 Then
        Beep(500, 1000)
        $hTime = TimerInit()
    EndIf

Until _IsPressed("51", $hDLL)

DllClose($hDLL)

 

Some of my script sourcecode

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