Send Input is not working

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
User avatar
Nextron
Posts: 1391
Joined: 01 Oct 2013, 08:23
Location: Netherlands OS: Win10 AHK: Unicode x32

Re: Send Input is not working

10 Sep 2015, 13:26

sik wrote:This hotstring
:SIR:parabola::parábolaxxxxxxx
followed by rapidly typed lll generated this
Lparábolaxxlxxxxx l
Could you repeat this, and afterwards look at AHK's key history.
You said the elapsed time between key events shows to be 0.00. In the key history, do you see the additional characters you manually typed at the end of the hotstring or mixed in?
sik
Posts: 22
Joined: 07 Sep 2015, 10:59

Re: Send Input is not working

10 Sep 2015, 13:55

I triggered it with space followed by kkkk and got this
kparábolkaxxxxxxxk k
As you can see, one k got ahead of the playback, and one in the middle, and one ahead of the space.
And in the key history, it only shows the k key comming up at the end plus one more down up cycle.
Of course, the first series of key events here is where I was typping the trigger and it shows one key going down before the last one came up.
20 039 u 0.13 Space
50 019 d 1.15 p
41 01E d 0.09 a
50 019 u 0.05 p
41 01E u 0.06 a
52 013 d 0.06 r
41 01E d 0.11 a
52 013 u 0.06 r
41 01E u 0.06 a
42 030 d 0.16 b
42 030 u 0.08 b
4F 018 d 0.50 o
4F 018 u 0.12 o
4C 026 d 0.23 l
4C 026 u 0.14 l
41 01E d 0.17 a
41 01E u 0.13 a
20 039 s d 10.27 Space
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
08 00E i d 0.00 Backspace
08 00E i u 0.00 Backspace
50 019 i d 0.00 p
50 019 i u 0.00 p
41 01E i d 0.00 a
41 01E i u 0.00 a
52 013 i d 0.00 r
52 013 i u 0.00 r
42 030 i d 0.00 b
42 030 i u 0.00 b
4F 018 i d 0.00 o
4F 018 i u 0.00 o
4C 026 i d 0.00 l
4C 026 i u 0.00 l
41 01E i d 0.00 a
41 01E i u 0.00 a
58 02D i d 0.00 x
58 02D i u 0.00 x
58 02D i d 0.00 x
58 02D i u 0.00 x
58 02D i d 0.00 x
58 02D i u 0.00 x
58 02D i d 0.00 x
58 02D i u 0.00 x
58 02D i d 0.00 x
58 02D i u 0.00 x
58 02D i d 0.00 x
58 02D i u 0.00 x
58 02D i d 0.00 x
58 02D i u 0.00 x
20 039 i d 0.00 Space
20 039 i u 0.00 Space
4B 025 u 0.51 k
4B 025 d 0.01 k
4B 025 u 0.11 k
01 000 d 11.45LButton
01 000 u 0.11 LButton

I don't understand much about how this works, but it looks to me like, for whatever reason, while it is processing the replacement, it looses the ability to capture the keyboard atctivity, which goes straight to the screen or other program.
sik
Posts: 22
Joined: 07 Sep 2015, 10:59

Re: Send Input is not working

10 Sep 2015, 19:39

And as mentioned before, this same script still performs flawlessly on my 32 bit Win8 notebook. I can make a long hotstring that takes quite a while to playback, but all keystrokes typed while it is playing only come in at the end.
lexikos
Posts: 9599
Joined: 30 Sep 2013, 04:07
Contact:

Re: Send Input is not working

10 Sep 2015, 20:36

AutoHotkey does not "capture the keyboard activity" in order to buffer the user's keystrokes; the buffering is done automatically by the Win32 SendInput() function, except - as I noted before - when another hook is present.

In other words, you have one or both of the following:
  • Another script running with a keyboard or mouse hook, causing SendInput to fall back to SendEvent.
  • Another program with a keyboard or mouse hook which isn't detected by AutoHotkey, causing SendInput to become unreliable.
User avatar
Nextron
Posts: 1391
Joined: 01 Oct 2013, 08:23
Location: Netherlands OS: Win10 AHK: Unicode x32

Re: Send Input is not working

11 Sep 2015, 09:09

/me Trying to understand the posted key history. If something is causing the delay in output, shouldn't it also be visible as an increased elapsed time in key history? Also, not all of the physically pressed k's show, even though AHK has the keyboard hook installed.
sik
Posts: 22
Joined: 07 Sep 2015, 10:59

Re: Send Input is not working

17 Sep 2015, 14:28

Ok, I finally got this figured out.
The problem was a program called "G-Buster Browser Defense" by Gas Tecnogies that is installed by several Brazilian banks if you use IE for online banking.
Besides being a resource hog, always running in background, it apparently does a certain ammount of keylogging all the time and must use a low level keyboard hook to do so.
It was an ordeal to get rid of it (that is another story), but with it gone my autocorrect script runs way faster Send Input works properly again.
Thanks for the help in figuring out what was going on.
TheSimonizer

Re: Send Input is not working

02 Dec 2015, 17:46

sik wrote:I tried like this sendmode,input and like this sendmode, input and neither one made any difference.
The space he meant was the one in between send and mode, not the one between , and input.

Also, In the script you copied, you put "send mode", not "sendmode" as above.

Make sure that sendmode is 1 word. "sendmode, input"
djilll

Re: Send Input is not working

19 Sep 2017, 10:33

Hi,

This is old post but same problem here:

I use it to fillup adress automatically

Send olboom

And the computer goes suddently completly Crazy! opening windows loging out etc

change to "Send aalboom" for example and it works perfectly!!! Was using version 15.1 went to 1.26.1 but same pb Windows 7 32Bits.

Seems to me AutoKeys interpret this string like some code and not some input
meanwhile the view is fine????

DON'T WORK!!!
11 01D i d 4.46 Control billing information - Mozilla Firefox
11 01D i u 0.00 Control
5B 15B i u 0.00 LWin
4F 018 i d 0.00 o
4F 018 i u 0.00 o
4C 026 i d 0.00 l
4C 026 i u 0.00 l
42 030 i d 0.00 b
42 030 i u 0.00 b
4F 018 i d 0.00 o
4F 018 i u 0.00 o
4F 018 i d 0.00 o
4F 018 i u 0.00 o
4D 032 i d 0.00 m
4D 032 i u 0.00 m
20 039 i d 0.00 Space
20 039 i u 0.00 Space
45 012 i d 0.00 e
45 012 i u 0.00 e
55 016 i d 0.00 u
55 016 i u 0.00 u
52 013 i d 0.00 r
52 013 i u 0.00 r
11 01D i d 0.00 Control
5B 15B i d 0.00 LWin
11 01D i u 0.00 Control

WORKS!
11 01D i d 7.33 Control billing information - Mozilla Firefox
11 01D i u 0.00 Control
5B 15B i u 0.00 LWin
41 01E i d 0.00 a
41 01E i u 0.00 a
41 01E i d 0.00 a
41 01E i u 0.00 a
41 01E i d 0.00 a
41 01E i u 0.00 a
4F 018 i d 0.00 o
4F 018 i u 0.00 o
4F 018 i d 0.00 o
4F 018 i u 0.00 o
4D 032 i d 0.00 m
4D 032 i u 0.00 m
20 039 i d 0.00 Space
20 039 i u 0.00 Space
45 012 i d 0.00 e
45 012 i u 0.00 e
55 016 i d 0.00 u
55 016 i u 0.00 u
52 013 i d 0.00 r
52 013 i u 0.00 r
11 01D i d 0.00 Control
5B 15B i d 0.00 LWin
11 01D i u 0.00 Control

Warms Regards,

Gilles

PS:Nice program by the way.
User avatar
Nextron
Posts: 1391
Joined: 01 Oct 2013, 08:23
Location: Netherlands OS: Win10 AHK: Unicode x32

Re: Send Input is not working

19 Sep 2017, 11:21

Sound like the modifier keys aren't being logically released for some reason. You could make the first line of your hotkey KeyWait LWin.

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: gabelynn1, mikeyww and 362 guests