Win active Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Aoky Carmona
Posts: 3
Joined: 19 Jul 2018, 21:45

Win active

20 Jul 2018, 12:08

Hi, I program this code:

Code: Select all

If WinActive, ahk_class indesign
	{MButton:: Send, {Space Down}{LButton Down}
	MButton Up:: Send, {Lbutton Up}{Space Up}
	Return
	}
But if I change to any aplication (like chrome or windows explorer) it keeps doing the same function.
gregster
Posts: 9012
Joined: 30 Sep 2013, 06:48

Re: Win active  Topic is solved

20 Jul 2018, 12:18

Please look up context-sensitive hotkeys and the difference between commands and #-directives

Code: Select all

#IfWinActive, ahk_class indesign
	MButton:: Send, {Space Down}{LButton Down}
	MButton Up:: Send, {Lbutton Up}{Space Up}
#If
You could start with the tutorial: https://autohotkey.com/docs/Tutorial.htm#s22 - but don't stop there!
Also compare your other thread: https://autohotkey.com/boards/viewtopic ... 27#p229350

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Google [Bot], mebelantikjaya, Rohwedder and 338 guests