Calling .ahk script fast causes taskbar to flicker

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
AnonymousAHK
Posts: 2
Joined: 08 Jun 2023, 11:25

Calling .ahk script fast causes taskbar to flicker

Post by AnonymousAHK » 08 Jun 2023, 11:47

So, I am having an issue with calling an .ahk script. I am using PowerShell to call and launch the AHK script. In my scenario, this script call is in a loop that gets called within .2 to .3 seconds every time it is called. All works fine with the script, but the issue I am running into is the Taskbar "flickers" and does not allow you to right click on an empty area without it making the right click menu disappear constantly rendering it useless.

From what I have noticed, it seems the AHK "window" is stealing focus so quickly each time the ahk script is called that is makes the right click menu essentially unusable. Is there anyway to prevent the ahk script call from stealing focus? I have looked around everywhere for a solution with AHK. I did find the "NoActivate" option, but that unfortunately does allow the rest of the script to finish/complete.

PowerShell script:

Code: Select all

Do { 

Start-Process "Path\Script.ahk"

Start-Sleep -Milliseconds 200

}
*I initially thought it was my ahk script contents, but I even tried using a blank ahk script and the issue happens still. Issue happens in a .exe as well. This also happens in Windows 10 & 11.

AnonymousAHK
Posts: 2
Joined: 08 Jun 2023, 11:25

Re: Calling .ahk script fast causes taskbar to flicker

Post by AnonymousAHK » 08 Jun 2023, 20:55

For the "I did find the "NoActivate" option, but that unfortunately does allow the rest of the script to finish/complete.", I meant to say it does NOT allow the rest of the script to run/finish.

Post Reply

Return to “Ask for Help (v1)”