2 Macros in 1 Script With Toggle
Posted: 14 Sep 2017, 10:45
Hallo. I dont know Eng so much. I need to run 2 macros in 1 script with toggle key, i have a script but its not working. Msgbox saying to me "Line 23 SendTheKey - Error: Duplicate label - Program will exit."
Code
LShift::
RepeatKey := !RepeatKey
If RepeatKey
SetTimer, SendTheKey, 20
Else
SetTimer, SendTheKey, Off
Return
SendTheKey:
SendInput 7
SendInput 7
SendInput 8
Return
RShift::
RepeatKey := !RepeatKey
If RepeatKey
SetTimer, SendTheKey, 100
Else
SetTimer, SendTheKey, Off
Return
SendTheKey: line 23 is here
SendInput z
SendInput 3
SendInput z
SendInput 3
Return
Code
LShift::
RepeatKey := !RepeatKey
If RepeatKey
SetTimer, SendTheKey, 20
Else
SetTimer, SendTheKey, Off
Return
SendTheKey:
SendInput 7
SendInput 7
SendInput 8
Return
RShift::
RepeatKey := !RepeatKey
If RepeatKey
SetTimer, SendTheKey, 100
Else
SetTimer, SendTheKey, Off
Return
SendTheKey: line 23 is here
SendInput z
SendInput 3
SendInput z
SendInput 3
Return