CapsLock and ControlSend Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
User avatar
ibieel
Posts: 216
Joined: 17 Oct 2021, 23:30

CapsLock and ControlSend

25 Dec 2021, 21:15

hello guys, I realized that AHK turns off the capslock when executing "ControlSend".
so, when I'm writing some sentence in CAPSLOCK (while running ControlSend), the sentence goes like this: "ThiS IS thE SEntENce". :crazy:

would have to add some command so that if the capslock is turned on, not turn it off while running "ControlSend". ??? :headwall:
User avatar
TLM
Posts: 1608
Joined: 01 Oct 2013, 07:52
Contact:

Re: CapsLock and ControlSend  Topic is solved

26 Dec 2021, 17:09

ibieel wrote:
25 Dec 2021, 21:15
would have to add some command so that if the capslock is turned on, not turn it off while running "ControlSend". ???
Try adding SetStoreCapsLockMode, Off before the ControlSend command.

The only downside is your what ever you're sending to the control will now be affected by Capslock.
In this case, i'd use ControlSetText instead of ControlSend.
User avatar
ibieel
Posts: 216
Joined: 17 Oct 2021, 23:30

Re: CapsLock and ControlSend

26 Dec 2021, 17:44

TLM wrote:
26 Dec 2021, 17:09
Try adding SetStoreCapsLockMode, Off before the ControlSend command.

The only downside is your what ever you're sending to the control will now be affected by Capslock.
In this case, i'd use ControlSetText instead of ControlSend.
my script has several controlsend, do i need to put the command "SetStoreCapsLockMode, Off" before all the "ControlSend" ?
amateur+
Posts: 655
Joined: 09 Oct 2021, 15:43

Re: CapsLock and ControlSend

26 Dec 2021, 18:19

Read the documentation of SetStoreCapsLockMode:
Every newly launched thread (such as a hotkey, custom menu item, or timed subroutine) starts off fresh with the default setting for this command. That default may be changed by using this command in the auto-execute section (top part of the script).
Have found any drawback in my code or approach? Please, point it out. /The moderator ordered to remove the rest of the signature, I had obeyed.
And I really apologize for our russian president. Being a citizen of an aggressor country is very shameful. Personally I tried to avoid this trying to defend elections from fraud being a member of the election commission of one of the precincts but only was subjected to a hooligan attack and right before the vote count was illegally escorted from the polling station and spent the night behind bars (in jail) in a result of illegal actions of corrupt policemen.

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Bing [Bot], CoffeeChaton and 153 guests