I would like a code that when I held the "x" key , according to the time I held it, performed a different action. For example:
Just click the x: type "a"
Hold x for 30 ms: type "a" as soon as pressed and "b" as soon as 30 ms
Hold x for 60 ms: type "a" as soon as pressed; "b" as soon as it gives 30 ms; and type "c" as soon as 60 ms
List of keys or a part of list accord the time the key was pressed Topic is solved
Re: List of keys or a part of list accord the time the key was pressed Topic is solved
Hallo,
try:
try:
Code: Select all
$x::
While GetKeyState("x","P") And A_Index < 27
{
Key := Chr(96 + A_Index)
Send, {%Key% Down}
Sleep, 30
Send, {%Key% Up}
}
Return
Re: List of keys or a part of list accord the time the key was pressed
Very interesting! I don't know how this comands work and the script is typing the whole alphabet!I use "d, e, f..." to other actions. Do you have other script, I was trying using Tickcount but it doesn't work
Thanks for the attention!
Thanks for the attention!
Re: List of keys or a part of list accord the time the key was pressed
If you only want to type the first 3 letters a - c replace < 27 with < 4