Script GUI to show when a script is running and active or inactive plus start and stop toggle Topic is solved

Get help with using AutoHotkey and its commands and hotkeys
The1TruJok3r

Script GUI to show when a script is running and active or inactive plus start and stop toggle

14 Apr 2017, 09:34

Extremely new to AutoHotkey and I'm using the script below but I want to add a visual indication when the script is running or not running. As an example say when it's toggled to start with the F5 key it would overlay a translucent green dot and when it's stopped it would overlay a translucent red dot and the dot could be moved around on the screen and is always on top. Any help would be appreciated.

Script:

F5::
if !init
{
WinGetActiveTitle, winid
init := 1
}
SetTimer, PressTheKey, % (t:=!t) ? 10000 : "Off"
return

PressTheKey:
ControlSend,, g, %winid%
return

IsPaused := false
Gui, Add, Button, w100 vPauseButton Default, Pause
Gui, Show
return
HotKeyIt
Posts: 1314
Joined: 29 Sep 2013, 18:35
Contact:

Re: Script GUI to show when a script is running and active or inactive plus start and stop toggle

14 Apr 2017, 18:10

Try this:

Code: [Select all] [Expand] [Download] GeSHi © Codebox Plus

The1TruJok3r

Re: Script GUI to show when a script is running and active or inactive plus start and stop toggle

15 Apr 2017, 15:44

HotKeyIt wrote:Try this:

Code: [Select all] [Expand] [Download] GeSHi © Codebox Plus




It does show the dot and it does toggle color but it's not sending the G key to the window. As a test I opened up notepad and launched the script. The gui color worked like a charm but nothing was being sent to the window. Any idea?
HotKeyIt
Posts: 1314
Joined: 29 Sep 2013, 18:35
Contact:

Re: Script GUI to show when a script is running and active or inactive plus start and stop toggle

15 Apr 2017, 17:26

Works fine for me, are you sure notepad was active when you pressed F5 and you did wait 10 seconds?
The1TruJok3r
Posts: 1
Joined: 21 Apr 2017, 07:09

Re: Script GUI to show when a script is running and active or inactive plus start and stop toggle  Topic is solved

21 Apr 2017, 07:18

HotKeyIt wrote:Works fine for me, are you sure notepad was active when you pressed F5 and you did wait 10 seconds?


For whatever reason wasn't working but now it is. Thanks so much for the help.

Return to “Ask For Help”

Who is online

Users browsing this forum: astrals, Bing [Bot] and 33 guests