Jump to content

Recommended Posts

Guest PapyToxik
Posted (edited)

  Quote

i think one of us may be misinterpretting his intent... (would not be a first for me) to me it looks like he wants the key held for ten seconds, but is unhappy with the 10 second delay prior to the send.

I want the key to be simply held for 10 seconds. I don't this pause before the send.

:P

Hope you understood me cause my english is not very good ;)

  Valuater said:

$begin = TimerInit()

While 1

Send("e")

$dif = TimerDiff($begin)

if $dif >= 10000 Then

    MsgBox(0,"Time Difference",$dif)

    ExitLoop

EndIf

WEnd

It's almost what i wanna do, but that's not exactly the same thing. The key is not held...

Edited by PapyToxik
Posted

  Valuater said:

it's the next line that states "pressed for 10 seconds as quickly as possible..."

but your are correct with your code "holding down" the "e" key.

8)

<{POST_SNAPBACK}>

actually that line is what made me think it was the initial 10 second delay he mentioned that was causing his problem.
Posted

  PapyToxik said:

I want the key to be simply held for 10 seconds. I don't this pause before the send.

:P

Hope you understood me cause my english is not very good  ;)

It's almost what i wanna do, but that's not exactly the same thing. The key is not held...

<{POST_SNAPBACK}>

check the code that i already posted... it holds the key for ten seconds...
Posted (edited)

ok... thanks to Cameronsdad and Valuater... this does both

$begin = TimerInit()
Send("{e down}")
ToolTip("e down")
While 1
    Send("e")
    $dif = TimerDiff($begin)
    if $dif >= 10000 Then
        MsgBox(0,"Time Difference",$dif)
        Send("{e up}")
        ExitLoop
    EndIf
WEnd

8)

Edited by Valuater

NEWHeader1.png

Posted

  jpm said:

May I say again is the bug in all release of Autoit official and beta that will be corrected in 3.1.1.75 beta ;)

<{POST_SNAPBACK}>

glad to hear that it will be corrected, and i swear i did see that the first time you said it, i just wanted to try to provide a workaround that they could implement immediately
Posted (edited)

  jpm said:

will be corrected in 3.1.1.75 beta

Hi JPM, I have beta 75 now, but now the code sends one "e" without any delay. Shouldn't it send e's for 10 seconds? Boy am I confuuzed...

;)

opt("SendKeyDownDelay",10000)
WinActivate("Untitled - Notepad")
send("e")
Edited by jefhal
...by the way, it's pronounced: "JIF"... Bob Berry --- inventor of the GIF format
Posted

  jefhal said:

Hi JPM, I have beta 75 now, but now the code sends one "e" without any delay. Shouldn't it send e's for 10 seconds? Boy am I confuuzed...

;)

opt("SendKeyDownDelay",10000)
WinActivate("Untitled - Notepad")
send("e")

<{POST_SNAPBACK}>

in fact the e appear right away but the key is released only 10 sec after

opt("SendKeyDownDelay",10000)
WinActivate("Untitled - Notepad")
$start=TimerStart()
send("ee")
msgbox(0,"diff",timerdiff($start))

You can verify it with the following code

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