miketh2005 Posted October 1, 2010 Posted October 1, 2010 (edited) HotKeySet("+", "ticket") HotKeySet("{TAB}", "arrest") While 1 = 1 WEnd Func ticket() MouseClick("left") Send("{TAB}") Send("{TAB}") EndFunc ;==>ticket Func arrest() Send("{TAB}") Send("{ENTER}") EndFunc ;==>arrest I have this code and it's just not working at all, but if I replace tab and shift with 1 and 2, then it works. Why? Thanks! Edited October 1, 2010 by miketh2005
BrewManNH Posted October 1, 2010 Posted October 1, 2010 The shift key can not be used as a hotkey, it's not allowed and/or seen by the program. As to your Tab key not working, not a good idea to use an unmodified key like Tab for a hotkey, and then use it as a key to be sent, I'm sure it's going to screw something up. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator
miketh2005 Posted October 1, 2010 Author Posted October 1, 2010 (edited) The shift key can not be used as a hotkey, it's not allowed and/or seen by the program. As to your Tab key not working, not a good idea to use an unmodified key like Tab for a hotkey, and then use it as a key to be sent, I'm sure it's going to screw something up.I see what you mean. I'm trying to make a process faster, and EVERY SECOND COUNTS, literally with this process, so I can't be using combination keys like Shift + 1 etc. its simply not fast enough. I tried using 1 and 2 as hotkeys, but the buttons simply aren't big enough on my keyboard, so sometimes in the heat of the moment when I'm hurrying fast, I press the wrong button, for example I press 2, when I meant to press 1 and then its done for me. Any suggestions, or do I just have to make due with "`" and "1"?What about the ctrl or alt key? Edited October 1, 2010 by miketh2005
BrewManNH Posted October 1, 2010 Posted October 1, 2010 (edited) HotKeySet Edited October 1, 2010 by BrewManNH If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator
nf67 Posted October 1, 2010 Posted October 1, 2010 Personally I always use the Home, Page up or Page down key. They allow for quick access and they don't get much use anyway.
miketh2005 Posted October 1, 2010 Author Posted October 1, 2010 Thanks for the thought. They would be too far away from the letters, and since every millisecond counts, it wouldn't be viable. I am using "Esc" and "F2" keys now, which are doing quit well Thanks. You can close if you want.
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