I don't understand why you're doing this.
Every time you reply, you give a solution that will work in your particular example, but that won't work in my script.
Your last example works because you're not using hotkeys. My code uses hotkeys and labels. See the difference ?
You know perfectly my code. I have posted it many times in this topic. It's a very simple code.
That code uses a
hotkey command which needs to call a label.
A LABEL. It can't call a function, because as far as I understand, that's forbidden :
https://www.autohotkey.com/docs/commands/Hotkey.htm
That's why I've been using the
TakeAction label since forever.
Now you are posting a new-new-new example (II won't call it a solution, just an example), and for unknown reasons, you took the liberty of transforming the
TakeAction label into a
callIt FUNCTION. So my
hotkey command can't call it anymore. Why would you do that ? I don't know.
I'm getting tired of this. I had a working mechanism and I was happy with it, but you said it could be improved by reducing the number of IniReads.
I could have said "I don't care", but since I think of all the people that are going to use my code, I'd like it to be as efficient as possible.
For THEM, not for me.
So I've swallowed my pride and asked your help once again (asking help repeteadly is not easy, you know). I have explained very precisely what my code was and how it worked (in case it wasn't clear enough).
And instead of simply adapting my code, you keep on answering with yet another example that CAN'T EASILY BE TRANSPOSED TO MY CODE !!! Why are you doing this ???
Was it too much to ask that you simply corrected the TakeAction label, like I explicitly requested in my last post ?
Jose Hidalgo wrote: ↑10 Jun 2021, 18:01
The only part that needs to be modified is TakeAction, so it generates the proper code to call each function with the right arguments. Just like it does right now with the previous non-optimized version of the code.
I am an absolute beginner in AHK world. I think everybody here knows that. Every one of your posts makes me feel even more beginner, which I believe is not their intended purpose. Or is it ?
And yet I've managed to pull out a script that's currently 2.500 lines long and WORKS. Giving it several months of my life when nothing is forcing me to. Just
to help others. I don't think a lot of people could do that for their first script.
Maybe that deserves a little more
appreciation, support and understanding. Not just examples that can't be transposed, like puzzle pieces that don't fit.
I don't know. I'm not expecting anything at this point. Just strongly disappointed, that's all.