I'm an absolute amateur when it comes to AHK and while I've managed to wrap my head around most of the logic and syntax, this one problem keeps tripping me up something fierce.
I'm looking to cycle different lists while a modifier key is held down, similar to how clipjump (http://clipjump.sourceforge.net/) works with cycling through paste selections. I just can't figure out how to tear enough Franken-code out of it to apply to my problem.
I'm trying to make "n" number of lists that I can populate as arrays with strings (but if there's a better way, please do let me know!) :
Code: Select all
list1 = ["hello", "hi there", "greetings!"]
list2 = ["goodbye", "see you soon", "take care!"]
I'm struggling to figure out how to:
- Get this to work in a While(get keystate) statement for when ctrl is held. I thought Keywait would be the answer, but I'm pretty sure I need a delay between [ListHotKey] presses; a single tap adds a count per ms, whipping through my selection too fast. I find this method unreliable for when I want to cycle selections very quickly.
- Break the loops and reset the counter to swap between lists without releasing ctrl, and
- Ensure this macro is scale-able (since I intend on having 9+ arrays and hotkeys).
I've made about 5 or 6 attempts at this now, scoured the helpdoc, hunted through the forums, and nothing is working. I'm not even sure I'm on the right track anymore. Any advice, tips, guidance, other threads, or code would be greatly appreciated!
Thanks in advance, everyone
-Pirate