Jump to content

wait for a click...


Recommended Posts

#include <misc.au3>
Func _ClickWait()
    While (_IsPressed('01') == 0)
        sleep(10)
    WEnd
EndFunc

_ClickWait()
MsgBox(0, "", "Done!")

This ought to work.

Was going to make'em work for it. :whistle:

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

k thanks all, but now how do I make this repeat, so that every time I click it would say "done!"? I tried putting buth of the scripts into a While 1 loop but it just says I dont have a WEND to go with it..

EDIT: Nvm thanks, I found it

Edited by P a R a D o X

If I hadn't said thank you yet, and you deserve it, than thank you...

Link to comment
Share on other sites

k thanks all, but now how do I make this repeat, so that every time I click it would say "done!"? I tried putting buth of the scripts into a While 1 loop but it just says I dont have a WEND to go with it..

EDIT: Nvm thanks, I found it

Oh, we thought you just wanted it to pause until it was clicked.

While 1
    If _IsPressed("01") Then
        MsgBox(0,"","You Clicked!")
    EndIf
    Sleep(100)
WEnd

EDIT: Sorry, Missed your edit..

Edited by Paulie
Link to comment
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
 Share

  • Recently Browsing   0 members

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