My Script is pressing down the Shift key

Get help with using AutoHotkey and its commands and hotkeys
Guest

My Script is pressing down the Shift key

14 Apr 2018, 21:28

I am developing a very simple script, and have come across something that seems like a bug. The code below when compiled also presses the shift key. I have no reason why. I have deduced the Send, {E} line causes it though. As far as I understand, that line is only supposed to press the E key and nothing more. Thanks for any help.

Using Ahk2Exe.exe version 1.1.28.2.

Code: Select all

V::
	Send, {LCtrl Down}
	Sleep, 10
	Send, {E}
	Send, {LCtrl Up}
hunter99
Posts: 126
Joined: 20 Jan 2014, 17:57

Re: My Script is pressing down the Shift key

15 Apr 2018, 07:25

This should do it:

SendInput +e

hunter99
swagfag
Posts: 2901
Joined: 11 Jan 2017, 17:59

Re: My Script is pressing down the Shift key

15 Apr 2018, 09:25

Send, {E} sends shift + lowercase e as per the docs

everything is working as intended
hunter99
Posts: 126
Joined: 20 Jan 2014, 17:57

Re: My Script is pressing down the Shift key

15 Apr 2018, 13:52

swagfag, you are a 100% right. I didn't read the OP correctly and was mistook what he/she was asking.

For the OP, here is the quote from the docs.

"•If one or more modifier keys have been put into effect by the Send command, or if the letter is wrapped in braces, it is sent as a keycode (modified with Shift if the letter is upper-case). This allows the script to easily activate standard keyboard shortcuts."

hunter99

Return to “Ask For Help”

Who is online

Users browsing this forum: anaxio, Bad husband, Bing [Bot], eL Tux, Google [Bot], michael_jie and 165 guests