MikeP Posted May 2, 2008 Share Posted May 2, 2008 (edited) Hi. That litte script does the following : The mousewheel acts as a trigger than enable/disable the UP arrow pressed/released. What i'm asking now is.. does Autoit have a function allowing to simulate the fact I'm right-clicking and keeping the button pressed. I know about Opt("MouseClickDownDelay", 10) but it doesn't fit my need ... I want the click to stop when I'm pressing the mouswheel button again... and if I'm putting 1000000 as delay (that is.. 1000 seconds) ok the script will start well and the button kept pressed but what if I wanna stop before the end of the delay? Is there a way to cancel that clic even if the delay isn't over.. Or any other way around to script what i'm looking to do? #Include <Misc.au3> HotKeySet("{PAUSE}","QuitIt") $dll = DllOpen("user32.dll") $triggerKeydown = False $keydown = True While 1 If _IsPressed("04", $dll) Then $triggerKeydown = Not $triggerKeydown If $triggerKeydown Then Send("{UP down}") ;~ ;~ insert mouse right-clic down method ;~ $keydown = True Else If $keydown Then Send("{UP up}") ;~ ;~ cancel the mouse right-clic (or simulate right-clic up) ;~ $keydown = False EndIf EndIf Sleep(10) WEnd Func QuitIt() DllClose($dll) Exit EndFunc Thanks for your help Edited May 2, 2008 by MikeP Link to comment Share on other sites More sharing options...
james3mg Posted May 2, 2008 Share Posted May 2, 2008 MouseUp() and MouseDown()? "There are 10 types of people in this world - those who can read binary, and those who can't.""We've heard that a million monkeys at a million keyboards could produce the complete works of Shakespeare; now, thanks to the Internet, we know that is not true." ~Robert Wilensky0101101 1001010 1100001 1101101 1100101 1110011 0110011 1001101 10001110000101 0000111 0001000 0001110 0001101 0010010 1010110 0100001 1101110 Link to comment Share on other sites More sharing options...
MikeP Posted May 2, 2008 Author Share Posted May 2, 2008 (edited) ahaha so easy... thanks man. I think I'm blind When I read your post I was thinking.. noooo this can't be ...*browsing functions list....* .... and when I found them .. D'OH ! *feeling ashamed* Edited May 2, 2008 by MikeP Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now