need help for updating code

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Xen0Warrior
Posts: 1
Joined: 21 Jun 2021, 10:03

need help for updating code

21 Jun 2021, 10:11

I do not know how to code anything in Autohotkey
need help with updating this for new vers :idea

Code: Select all

$=::
 {
   toggle:=!toggle
   if (toggle)
    {
	  sendinput, {w down}{shift down}
    }
   else
    {
	  sendinput, {w up}{shift up}
    }
 }
return
[Mod edit: [code][/code] tags added.]
gregster
Posts: 9029
Joined: 30 Sep 2013, 06:48

Re: need help for updating code

21 Jun 2021, 10:16

For new version (?) of what ? what seems to be the problem with this code?
Please elaborate.
swagfag
Posts: 6222
Joined: 11 Jan 2017, 17:59

Re: need help for updating code

21 Jun 2021, 10:50

why, for the new version of ahk, of course :HeHe:

Code: Select all

#Requires AutoHotkey v2.0-a137-f6f65742

$=::
{
	static toggle := false
	if (toggle := !toggle)
		SendInput('{w down}{shift down}')
	else
		SendInput('{w up}{shift up}')
}

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Billykid, haomingchen1998, matt101, Oblomov228 and 246 guests