Search found 43 matches
- 14 Apr 2021, 22:47
- Forum: Ask for Help (v1)
- Topic: GUI slider position and then destroy once clicked outside the box
- Replies: 1
- Views: 191
GUI slider position and then destroy once clicked outside the box
I'm trying to show a slider (bottom right corner aligned) at the position of the mouse when clicked on the menu item, and then have it destroyed immediately when clicked out of, similar to how windows natively does it. I'm unsure of both. What am I missing? Also, is there a way to make the slider up...
- 12 Apr 2021, 00:24
- Forum: Ask for Help (v1)
- Topic: GUI image not showing on Windows 10
- Replies: 1
- Views: 270
GUI image not showing on Windows 10
I was recently and unfortunately forced to move to windows 10, and now one of my scripts is not displaying the GUI properly. I use it as a clickthru OSD on the bottom of my screen as I learn the new keyboard layout. But now all it displays is a colored box, the keyboard layout image I made doesn't s...
- 05 Jun 2019, 20:20
- Forum: Ask for Help (v1)
- Topic: Load script as administrator through exe
- Replies: 1
- Views: 575
Load script as administrator through exe
I have a renamed AutoHotkey exe (so that it will show in Task Manager) and I use a startup script to load it when I login to my account. But for some reason, it doesn't actually run as admin. When I manually right click the ahk and run as admin, it works just fine, but not when it loads through the ...
- 09 Dec 2018, 18:20
- Forum: Ask for Help (v1)
- Topic: Simplify uptime display code using RegEx
- Replies: 8
- Views: 2121
Re: Simplify uptime display code using RegEx
Easy Fix: I implemented your code, and although it does work perfectly and significantly reduces the number of lines, the MsgBox problem still exists. I've pinpointed the issue: it happens when the MsgBox is displayed when upTime is between 0 and 10 seconds. It drops off the final word of the MsgBo...
- 09 Dec 2018, 00:13
- Forum: Ask for Help (v1)
- Topic: Simplify uptime display code using RegEx
- Replies: 8
- Views: 2121
Re: Simplify uptime display code using RegEx
I ended up with this. Surprisingly still using the sleep cycle I had for testing. And now it also ticks along as the MsgBox is displayed :) sleepTime := A_TickCount timeFormat := "dddd, d MMM, h:mm:ss tt" bootTime := "" bootTime += -(A_TickCount // 1000), Seconds FormatTime, bootTime, %bootTime%, %t...
- 09 Dec 2018, 00:02
- Forum: Ask for Help (v1)
- Topic: Simplify uptime display code using RegEx
- Replies: 8
- Views: 2121
Re: Simplify uptime display code using RegEx
b/c you will never find "0 seconds %A_Space%", so it never gets replaced It's the simplest oversights that make us feel the dumbest >.< upTime := RTrim((d ? d . " day" . (d = 1 ? "" : "s") . ", " : "") . (h ? h . " hour" . (h = 1 ? "" : "s") . ", " : "") . (m ? m . " minute" . (m = 1 ? "" : "s") . ...
- 08 Dec 2018, 04:00
- Forum: Ask for Help (v1)
- Topic: Simplify uptime display code using RegEx
- Replies: 8
- Views: 2121
Simplify uptime display code using RegEx
This code works well as is, but I'm wondering if there's a more efficient way to display the perfected time without using so many If statements. Perhaps using RegExMatch to remove any zeros without a number before it (such as 10). Something like RegExMatch(string, "[^0-9](\d)", upTime) and then loop...
- 20 Nov 2018, 17:30
- Forum: Ask for Help (v1)
- Topic: Push Winkey to show autohidden taskbar
- Replies: 10
- Views: 2583
Re: Push Winkey to show autohidden taskbar
That's more similar to my first post, rather than my updated code, but thank you.
- 17 Nov 2018, 19:00
- Forum: Ask for Help (v1)
- Topic: Push Winkey to show autohidden taskbar
- Replies: 10
- Views: 2583
Re: Push Winkey to show autohidden taskbar
I never posted an update to the final working code. This works perfectly, albeit forcing LWin Up to do nothing. ~LWin:: IfWinActive, ahk_class Shell_TrayWnd Send, {Lwin} ; opens start menu Else { keyPressed := 0 WinGet, lastID, ID, A ; stores window ID to anticipate window change While GetKeyState("...
- 13 Mar 2018, 20:56
- Forum: Ask for Help (v1)
- Topic: Convert seconds to m:ss and display timer
- Replies: 5
- Views: 2679
Re: Convert seconds to m:ss and display timer
Thank you both! I like that single line solution, but I separated the formatting into a function, and then count up/down timers separately calling that function. A strange thing is happening though. As the up or down timer is ticking, for some reason (at least on my PC) it will jump exactly 40 secon...
- 09 Mar 2018, 19:56
- Forum: Ask for Help (v1)
- Topic: Convert seconds to m:ss and display timer
- Replies: 5
- Views: 2679
Re: Convert seconds to m:ss and display timer
Oh for goodness sake. I just needed to change the while statement to While (seconds >= 1) so it still multiplies to 100 at 60 the second intervals. I'll leave this here for anyone else who might be looking for a simple countdown timer script. However, the question remains. Is there an easier way to ...
- 09 Mar 2018, 19:37
- Forum: Ask for Help (v1)
- Topic: Convert seconds to m:ss and display timer
- Replies: 5
- Views: 2679
Convert seconds to m:ss and display timer
I've done all the math properly to get the formatting correct, but yet when the clock is ticking down, once it hits 60 seconds, the formatted timer disappears entirely. The other test timers I have in the tooltip still show accurately, so where is the formatted one going? This code "works" for conve...
- 10 Nov 2017, 17:00
- Forum: Ask for Help (v1)
- Topic: Change sound for Icon type MsgBox
- Replies: 3
- Views: 1677
Re: Change sound for Icon type MsgBox
Or if you use this in conjunction with NirCmd... Run, nircmd.exe MuteAppVolume SystemSounds 1 ; Only mutes system sounds, not everything SetTimer, PlaySound MsgBox, 16, Icon Hand, This has the "stop/error" icon, and sound has been temporarily muted. return PlaySound: WinWait, Icon Hand ; Wait for or...
- 08 Nov 2017, 20:33
- Forum: Ask for Help (v1)
- Topic: Change sound for Icon type MsgBox
- Replies: 3
- Views: 1677
Re: Change sound for Icon type MsgBox
Thank you for that very accurate method. I will try that out. For those who do not want to mess with the registry, I found a side route that works as well, albeit a ~0.5s delay in sound response. SoundSet, +0, Master, mute ; Mute sound SetTimer, PlaySound MsgBox, 16, Icon Hand, This has the "stop/er...
- 07 Nov 2017, 22:21
- Forum: Ask for Help (v1)
- Topic: Change sound for Icon type MsgBox
- Replies: 3
- Views: 1677
Change sound for Icon type MsgBox
Is it possible to use a different sound for the Icon MsgBoxes? Such as: MsgBox, 64, Icon Asterisk, This has the "info" icon, and also has the "info" sound. MsgBox, 16, Icon Hand, This has the "stop/error" icon, but I want it to have the "info" sound, not the "error" sound. Putting SoundPlay *64 righ...
- 23 Oct 2017, 12:48
- Forum: Ask for Help (v1)
- Topic: Push Winkey to show autohidden taskbar
- Replies: 10
- Views: 2583
Re: Push Winkey to show autohidden taskbar
I found that I could use GetKeyState instead of the KeyWait from before, that way I have as much time as my fingertips desire to press the other button. It's also a much cleaner code. Unfortunately, this isn't working correctly. Only about half the time does it actually activate the task bar, and th...
- 13 Aug 2017, 13:02
- Forum: Ask for Help (v1)
- Topic: Execute a program 30 minutes after startup Topic is solved
- Replies: 2
- Views: 1228
Re: Execute a program 30 minutes after startup Topic is solved
Code: Select all
SetTimer, RunApp, 1800000 ; 30 minutes
*other code*
RunApp:
SetTimer, RunApp, Off
Run, app.exe
- 13 Aug 2017, 00:17
- Forum: Ask for Help (v1)
- Topic: Hotkeys to activate SetPoint media keys
- Replies: 1
- Views: 647
Hotkeys to activate SetPoint media keys
I have a Logitech EX110 keyboard. I would like to have a hotkey activate a series of media keys, but I'm not sure if it's possible to send media functions via SetPoint software. Have we ever accomplished this before?
- 22 Jun 2017, 03:35
- Forum: Ask for Help (v1)
- Topic: Using ahk_process to send commands
- Replies: 4
- Views: 1098
Re: Using ahk_process to send commands
Ah, all I needed to substitute was process with exe. I didn't connect those (embarrassingly simple) dots. Thank you.
- 22 Jun 2017, 02:59
- Forum: Ask for Help (v1)
- Topic: Using ahk_process to send commands
- Replies: 4
- Views: 1098
Using ahk_process to send commands
Have we implemented ahk_process yet? I found a forum topic from 2006 saying it may be added soon, but upon testing, no luck. This is what I used to test: Insert:: WinGetClass, testClassA, A WinGet, testProcess, ProcessName, ahk_class %testClassA% WinGetTitle, testTitle, ahk_process %testProcess% Msg...