Search found 47 matches

by hiahkforum
11 Mar 2024, 11:31
Forum: Ask for Help (v2)
Topic: How to duplicate text of Edit control while editing? Topic is solved
Replies: 6
Views: 214

How to duplicate text of Edit control while editing? Topic is solved

How to duplicate text of Edit control while editing? Without clicking buttons and MsgBoxes, all changes only in current GUI, but Text control can be replaced with disabled Edit control. 1::{ Title := WinGetTitle('A') TableC := Gui('+AlwaysOnTop +ToolWindow', Title) TableC.Add('Text',, 'Batch name:')...
by hiahkforum
03 Mar 2024, 11:01
Forum: Ask for Help (v2)
Topic: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.
Replies: 9
Views: 273

Re: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.

Thank you for trying to help. I used MsgBox in the example only for ease of understanding, in fact there is no MsgBoxes in my code, only one InputBox and many SendEvents . I don't know if your example will work for me, I'll try to understand the code tomorrow. Here's a more precise example of my cur...
by hiahkforum
03 Mar 2024, 10:16
Forum: Ask for Help (v2)
Topic: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.
Replies: 9
Views: 273

Re: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.

This works: #MaxThreadsPerHotkey 2 w::{ MsgBox '1' } +w::{ MsgBox '2' } This works: #MaxThreadsPerHotkey 1 w::{ KeyWait 'w' if KeyWait('w', 'D T0.1') { MsgBox '2' } else { MsgBox '1' } } This doesn't work and instead of MsgBox 2 on double press it shows 2 windows with MsgBox 1 . #MaxThreadsPerHotkey...
by hiahkforum
03 Mar 2024, 08:48
Forum: Ask for Help (v2)
Topic: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.
Replies: 9
Views: 273

Re: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.

At the moment I have 2 scripts with hotkeys W and Shift + W , which I run in several threads simultaneously. My goal is to make the controls more convenient so that Shift + W becomes W x2 , but at the same time I want to maintain the ability to run 2 of these different codes at the same time. #MaxTh...
by hiahkforum
03 Mar 2024, 07:16
Forum: Ask for Help (v2)
Topic: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.
Replies: 9
Views: 273

Re: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.

With #MaxThreadsPerHotkey 1 everything works as expected - it shows MsgBox 1 when pressed once and MsgBox 2 when pressed twice. When you increase the #MaxThreadsPerHotkey value to 2 or higher, it always shows MsgBox 1 for any number of clicks. There's logic to this, but I'm wondering if there's a wa...
by hiahkforum
03 Mar 2024, 06:45
Forum: Ask for Help (v2)
Topic: Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.
Replies: 9
Views: 273

Simultaneous using of #MaxThreadsPerHotkey and KeyWait for double pressing function.

Is this possible to use #MaxThreadsPerHotkey and KeyWait simultaneously? I want to run my script in multiple threads, but using KeyWait for double pressing function instead of having another hotkey. #MaxThreadsPerHotkey 6 $w::{ KeyWait 'w' if KeyWait('w', 'D T0.1') { MsgBox '2' } else { MsgBox '1' }...
by hiahkforum
03 Mar 2024, 04:07
Forum: Ask for Help (v2)
Topic: Convert KeyWait/ControlSend script to v2 Topic is solved
Replies: 6
Views: 267

Re: Convert KeyWait/ControlSend script to v2 Topic is solved

flyingDman Thanks, I didn't see the error with the dot here: T.01 . I came up with this code that works for my purposes: #Requires AutoHotkey v2.0 Global MacrosMode := False HideTrayTip() { TrayTip } Alt::{ Global if KeyWait('Alt', 'D T0.1') { PostMessage 0x0050, 0, 0x4090409,, 'A' MacrosMode := Tr...
by hiahkforum
02 Mar 2024, 23:39
Forum: Ask for Help (v2)
Topic: Convert KeyWait/ControlSend script to v2 Topic is solved
Replies: 6
Views: 267

Re: Convert KeyWait/ControlSend script to v2 Topic is solved

boiler Thank you for the answer. I want to make CapsLock work as usual when pressed once, but execute my code when pressed twice. It doesn't seem to quite work. :( #Requires AutoHotkey v2.0 Global MacrosMode := False HideTrayTip() { TrayTip } CapsLock::{ Global KeyWait 'CapsLock' if KeyWait('CapsLo...
by hiahkforum
02 Mar 2024, 22:06
Forum: Ask for Help (v2)
Topic: Convert KeyWait/ControlSend script to v2 Topic is solved
Replies: 6
Views: 267

Convert KeyWait/ControlSend script to v2 Topic is solved

Hi, could you please tell me how to adapt this code to v2.0? KeyWait, Left KeyWait, Left, 'D T.01' If ErrorLevel ControlSend, , {Left}, ahk_exe vlc.exe else ControlSend, , ^{Left}, ahk_exe vlc.exe return [Mod action: Split post from an unrelated topic to this new thread. Please start new threads if ...
by hiahkforum
25 Feb 2024, 01:06
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

In fact, this "0" can be defeated, perhaps not the most correct way, but it works. You just need to erase the period in the quotes or remove the quotes altogether. Yes, it’s better with a period or space, but at least this way.

Code: Select all

!!Active++ "."
timer1.5.png
timer1.5.png (5.03 KiB) Viewed 661 times

Code: Select all

!!Active++ ""
timer2.png
timer2.png (4.33 KiB) Viewed 662 times
by hiahkforum
24 Feb 2024, 20:49
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

@Rohwedder Can I say that I love you? :superhappy: I know this “0” is a necessity, so I don’t dare ask you for anything else. Everything works great! :thumbup:
by hiahkforum
24 Feb 2024, 05:40
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

@Rohwedder HUGE thank you! This works incredible, exactly what I wanted! :dance: But one more small thing, is it possible, when the last timer ends, to reset the timer sequence number as well? :roll:
by hiahkforum
22 Feb 2024, 08:10
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

@Rohwedder Thank you, SoundPlay works perfectly! I mean something like that to quickly visually identify the order of the timers.
timer.png
timer.png (4.01 KiB) Viewed 759 times
by hiahkforum
22 Feb 2024, 06:30
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

Rohwedder Wow! :wtf: With each adjustment, the simple timer function looks more and more like rocket science! The circle countdown is very beautiful! :bravo: Of course, I meant "function". I am very grateful to you, a lot has already been done and I understand if this is all with help. But if I may...
by hiahkforum
21 Feb 2024, 10:08
Forum: Ask for Help (v2)
Topic: SoundBeep stopped making sounds after a single use of SoundPlay.
Replies: 3
Views: 114

Re: SoundBeep stopped making sounds after a single use of SoundPlay.

mikeyww I don't know what the heck it was, apparently it's some Windows side s*, but I swear, even a one-line script with only SoundBeep didn't work. I tried rebooting AHK, rebooting Windows, reinstalling AHK, tried to find something in the sound settings, but nothing worked so I decided to create ...
by hiahkforum
21 Feb 2024, 06:29
Forum: Ask for Help (v2)
Topic: SoundBeep stopped making sounds after a single use of SoundPlay.
Replies: 3
Views: 114

SoundBeep stopped making sounds after a single use of SoundPlay.

The title of the topic speaks for itself. I learned about SoundBeep and immediately fell in love with the feature. But I wanted to try to take it a step further and tried playing around with SoundPlay, I ran the SoundPlay A_ScriptDir '\Windows XP Shutdown.mp3' command once, but after playing it once...
by hiahkforum
21 Feb 2024, 06:16
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

Rohwedder This is a completely different timer implementation, but it works too, and even in multiple threads! :D But can I ask a couple of silly questions? How do I make a variable from this code, so I don't have to paste the whole code every time? And how do I make the timer appear at position x=...
by hiahkforum
20 Feb 2024, 20:58
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Re: Simultaneous running of two timers. Topic is solved

@Rohwedder Thank you for your help. It may work, but there is still only one ToolTip on the screen to visualize the timer. Is it possible to fix this?
by hiahkforum
20 Feb 2024, 05:00
Forum: Ask for Help (v2)
Topic: Simultaneous running of two timers. Topic is solved
Replies: 21
Views: 1003

Simultaneous running of two timers. Topic is solved

In the documentation I found an example of a timer that works well for me: counter := SecondCounter() ; An example class for counting the seconds... class SecondCounter { __New() { this.interval := 1000 this.count := -5 ; Tick() has an implicit parameter "this" which is a reference to ; the object, ...

Go to advanced search