Search found 217 matches

by Micromegas
26 May 2020, 02:15
Forum: Ask For Help
Topic: Is it possible to not reorder the key values of the output associative array when using a For loop? Topic is solved
Replies: 9
Views: 898

Re: Is it possible to not reorder the key values of the output associative array when using a For loop? Topic is solved

Thank you for the suggestion. Yes, that does deliver the output I want – but at the expense of mangling the data structure. The reason I called the variables “aa...” was that I have associate arrays given, and I just needed a way to display them nicely. But I found a workaround that keeps the data s...
by Micromegas
25 May 2020, 18:28
Forum: Ask For Help
Topic: Is it possible to not reorder the key values of the output associative array when using a For loop? Topic is solved
Replies: 9
Views: 898

Re: Is it possible to not reorder the key values of the output associative array when using a For loop? Topic is solved

Sorry for replying to last years post. For me, this is a problem. If there was a way to remember the order of the definition, it would be possible to use the following generic function: aa1 := {begin: 100, middle: 200, end: 300} aa2 := {top: 0, center: 10, bottom: 20} msgbox % ToString(aa1) msgbox %...
by Micromegas
04 Mar 2020, 05:52
Forum: Bug Reports
Topic: InputBox Locale changes the behavior in an unexpected way
Replies: 8
Views: 2590

Re: InputBox Locale changes the behavior in an unexpected way

Did I misunderstand the purpose of this forum? I posted this specifically under “Bug Reports” to report this, not to receive continuous tinkering with workarounds. I'm unsubscribing the topic now; if there is any comment that treats this as something like a bug report, please send me a private messa...
by Micromegas
28 Jan 2020, 02:44
Forum: Bug Reports
Topic: InputBox Locale changes the behavior in an unexpected way
Replies: 8
Views: 2590

InputBox Locale changes the behavior in an unexpected way

In v2, InputBox will have the Locale option as default. Therefore, I'm beginning to set it in my code. It turns out, that option changes the behavior in an unexpected, and IMHO not useful way: Instead of the text box, the Cancel button is selected. Repro steps: 1. Run InputBox, return_value, , , , ,...
by Micromegas
26 Nov 2019, 14:17
Forum: Ask For Help
Topic: Buffer keyboard input
Replies: 13
Views: 1073

Re: Buffer keyboard input

I saw that. That is why I wrote “GUI or Input”. To be clear, the point is that this needs to make things easier for the user. KISS. So, no InputBox, either. Nothing that would only make it worse for the user. https://upload.wikimedia.org/wikipedia/commons/thumb/7/75/Murner.Nerrenbeschwerung.kind.jpg...
by Micromegas
26 Nov 2019, 13:55
Forum: Ask For Help
Topic: Buffer keyboard input
Replies: 13
Views: 1073

Re: Buffer keyboard input

No, it's not that I'm picky. I have a very straightforward requirement; it's all in my first post: I don't need any GUI or Input, just a second of time for the script to do something before any further keys get displayed.
by Micromegas
26 Nov 2019, 13:12
Forum: Ask For Help
Topic: Buffer keyboard input
Replies: 13
Views: 1073

Re: Buffer keyboard input

Please, don't just post random complications to the code without trying it out yourself. The new code still has the same problem; except that it now writes the keyboard input, just like the output of the computation, into the text box of the otherwise completely useless unmotivated GUI. (It also cre...
by Micromegas
26 Nov 2019, 12:54
Forum: Ask For Help
Topic: Buffer keyboard input
Replies: 13
Views: 1073

Re: Buffer keyboard input

:eh: Did you try that yourself? :?: This is no better than the original. The subroutine named “catchKeys” doesn't catch any keys – just as in the original code example, they are simply passed on while the thread is running. (In fact, I could squeeze in many more characters before the output – but th...
by Micromegas
26 Nov 2019, 09:33
Forum: Ask For Help
Topic: Buffer keyboard input
Replies: 13
Views: 1073

Re: Buffer keyboard input

Hmm, that doesn't seem to solve my problem: I don't want the script to sleep; I only put Sleep in the above code to simulate the time the script takes for its task. (Sorry about the confusion; I edited my original post to make that clear.) Why specifically wait for Space ? The user can enter all kin...
by Micromegas
26 Nov 2019, 07:18
Forum: Ask For Help
Topic: Buffer keyboard input
Replies: 13
Views: 1073

Buffer keyboard input

Is there a way to hold off keyboard input until a thread is done? In other words, I'm looking for the opposite of KeyWait – make the key wait for the script. Sometimes (e.g. here ) it is recommended to “use the Critical command to buffer keyboard input”. However, the doc page only speaks of “other t...
by Micromegas
06 Oct 2019, 13:29
Forum: Other Programming Languages
Topic: Can anyone explain what this code does?
Replies: 3
Views: 3211

Re: Can anyone explain what this code does?

This is not an AHK question. Why don't you ask at the appropriate forum for the language?
by Micromegas
06 Oct 2019, 06:18
Forum: Ask For Help
Topic: Is there a way to detect text information on notepad and Microsoft Word? Topic is solved
Replies: 2
Views: 352

Re: Is there a way to detect text information on notepad and Microsoft Word? Topic is solved

What kind of text information do you mean? If you need the selected text you can use clipboard, as in the following:

Code: Select all

SendInput ^c
ClipWait 0.3
MsgBox % Clipboard
by Micromegas
06 Oct 2019, 06:13
Forum: Ask For Help
Topic: Variable Decreasing Overtime
Replies: 2
Views: 384

Re: Variable Decreasing Overtime

Have you tried SetTimer?
by Micromegas
06 Oct 2019, 05:59
Forum: Ask For Help
Topic: Hotkeys overriden by ms-gamingoverlay Topic is solved
Replies: 2
Views: 443

Re: Hotkeys overriden by ms-gamingoverlay Topic is solved

Update: Using a different version of AHK, which solved my other problem, didn't fix this one.
by Micromegas
06 Oct 2019, 05:51
Forum: Ask For Help
Topic: Unicode displayed as question marks Topic is solved
Replies: 3
Views: 562

Re: Unicode displayed as question marks Topic is solved

Thanks for your answers. I found the problem: AHK was installed as the ANSI version. (See https://www.autohotkey.com/docs/Program.htm#install) Running the file with the Unicode version of AHK fixes the issue.
by Micromegas
05 Oct 2019, 07:09
Forum: Ask For Help
Topic: Unicode displayed as question marks Topic is solved
Replies: 3
Views: 562

Unicode displayed as question marks Topic is solved

On a new (actually, refurbished) computer running Win 10 Professional, I have several fundamental problems. #2: Unicode displayed as question marks. Now f and g in the following, which got displayed nicely on my old box, just give me question marks: #Hotstring * ? ::f::ф g::Send г d::Send {U+0434} E...
by Micromegas
05 Oct 2019, 06:23
Forum: Ask For Help
Topic: Hotkeys overriden by ms-gamingoverlay Topic is solved
Replies: 2
Views: 443

Hotkeys overriden by ms-gamingoverlay Topic is solved

On a new (actually, refurbished) computer running Win 10 Professional, I have several fundamental problems. #1: Many of my shortcuts (both those using the Win key and those with the Alt key) bring up the XBox game bar (why?). I managed to uninstall that with the tips from https://gist.github.com/jos...
by Micromegas
16 May 2019, 12:27
Forum: Ask For Help
Topic: Alternative key to work after Menu Show Topic is solved
Replies: 2
Views: 535

Re: Alternative key to work after Menu Show Topic is solved

Thanks - that's what I've been looking for. It contains two great ideas: (1) Using the Input function to ensure that the assignment lasts just as long as needed. (2) exiting a whole script to end the temporary assignment. What's the "Send s" command for? I assume it's just left over from testing; I ...
by Micromegas
15 May 2019, 13:55
Forum: Ask For Help
Topic: Alternative key to work after Menu Show Topic is solved
Replies: 2
Views: 535

Alternative key to work after Menu Show Topic is solved

Is there a way to allow for an alternative key to trigger an entry in a menu created with Menu Show ? The following code does not, as I hoped, allow the CapsLock key to trigger the same choice as the hotkey c , since the hotkey reassignment doesn't work while the menu is shown. Menu, TopMenu, Add, &...

Go to advanced search