I'm trying to make a srcipt that allows me to have same Hotkeys with diferent Keystrokes depending the context.
f.e.: if I do "D" then sends DI, and after that command the next hotkeys will be "R", "D" and "L", sending RA, CD and LA respectively. After that exit with "Esc" and letting free the hotkeys "R", "D" and "L" for others Keystrokes.
My problem is about theory and syntax.
I've been strarting my code like this:
Code: Select all
WinActivate, ahk_exe Revit.exe
d::
var01 = Dimensions
Send, di
if(var01 = "Dimensions")
{
l::
Send, cl
a::
Send, ca
r::
Send, ra
i::
Send, cd
d::
Send, la
var01 = 0
Return
}
Return
If someone can give me some light about this I'll be very grateful.