gamepin126 Posted September 4, 2006 Posted September 4, 2006 (edited) This is all the pertinent code to what I'm about to ask. Is there a way to have changeable command keys via HotKeySet ie: Ctrl, Shift, Alt. Also, I strained my brain over trying to consolidate the 1-10 functions into one better one. All that's different out of all of those, is is 1 number in a couple places. I'm using radio buttons as command key choices. Enter() is just a toggle function. ]$KeyMod = "" HotKeySet($KeyMod & "1", "Msg1") HotKeySet($KeyMod & "2", "Msg2") HotKeySet($KeyMod & "3", "Msg3") HotKeySet($KeyMod & "4", "Msg4") HotKeySet($KeyMod & "5", "Msg5") HotKeySet($KeyMod & "6", "Msg6") HotKeySet($KeyMod & "7", "Msg7") HotKeySet($KeyMod & "8", "Msg8") HotKeySet($KeyMod & "9", "Msg9") HotKeySet($KeyMod & "0", "Msg0")oÝ÷ Ù«¢+Ø)]¡¥±Ä($ÀÌØíµÍôÕ¥Ñ5Í ¤(%M±Ð(% ÍÀÌØíµÍôÀÌØíU%}Y9Q} 1=M($%á¥Ñ1½½À( ÍÀÌØíµÍôÀÌØíI} Ñɰ¹ ¥Ñ9¡U% ÑɱI ÀÌØíI} Ñɰ¤°ÀÌØíU%} ! -¤ôÀÌØíU%} ! -(ÀÌØí-å5½ôÅÕ½ÐíxÅÕ½Ðì( ÍÀÌØíµÍôÀÌØíI}M¡¥Ð¹ ¥Ñ9¡U% ÑɱI ÀÌØíI}M¡¥Ð¤°ÀÌØíU%} ! -¤ôÀÌØíU%} ! -(ÀÌØí-å5½ôÅÕ½Ðì¬ÅÕ½Ðì( ÍÀÌØíµÍôÀÌØíI}±Ð¹ ¥Ñ9¡U% ÑɱI ÀÌØíI}±Ð¤°ÀÌØíU%} ! -¤ôÀÌØíU%} ! -(ÀÌØí-å5½ôÅÕ½ÐìÌÌìÅÕ½Ðì(% ͱÍ($$ììììììì(%¹M±Ð)]¹)á¥Ñl½ÕѽѥÑt( CODEFunc Msg1() $Msg1 = GUICtrlRead($Input1) Enter() Send($Msg1, 1) Send("{ENTER}") EndFunc Func Msg2() $Msg2 = GUICtrlRead($Input2) Enter() Send($Msg2, 1) Send("{ENTER}") EndFunc Func Msg3() $Msg3 = GUICtrlRead($Input3) Enter() Send($Msg3, 1) Send("{ENTER}") EndFunc Func Msg4() $Msg4 = GUICtrlRead($Input4) Enter() Send($Msg4, 1) Send("{ENTER}") EndFunc Func Msg5() $Msg5 = GUICtrlRead($Input5) Enter() Send($Msg5, 1) Send("{ENTER}") EndFunc Func Msg6() $Msg6 = GUICtrlRead($Input6) Enter() Send($Msg6, 1) Send("{ENTER}") EndFunc Func Msg7() $Msg7 = GUICtrlRead($Input7) Enter() Send($Msg7, 1) Send("{ENTER}") EndFunc Func Msg8() $Msg8 = GUICtrlRead($Input8) Enter() Send($Msg8, 1) Send("{ENTER}") EndFunc Func Msg9() $Msg9 = GUICtrlRead($Input9) Enter() Send($Msg9, 1) Send("{ENTER}") EndFunc Func Msg0() $Msg0 = GUICtrlRead($Input0) Enter() Send($Msg0, 1) Send("{ENTER}") EndFunc Edited September 4, 2006 by gamepin126
gamepin126 Posted September 4, 2006 Author Posted September 4, 2006 (edited) thatsgreat2345 said: id recomend _Ispressed Can I use combo keys with _IsPressed? Like: If _IsPressed("some hex number") Then If _IsPressed("some hex number") Then ;;; Endif Endif ? EDIT: Would it be better to make 3 functions for SHIFTDOWN etc or just use the above? Edited September 4, 2006 by gamepin126
Thatsgreat2345 Posted September 4, 2006 Posted September 4, 2006 (edited) but of course press ctrl + shift + 0 (edit) #include <misc.au3> while 1 If _Ispressed("11") and _Ispressed("30") and _ISpressed("10") then Msgbox(0,"IT WORKS","IT WORKS") Wend Edited September 4, 2006 by thatsgreat2345
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now