Questions tagged [autohotkey]

AutoHotkey (AHK) is a free, open-source macro-creation and automation software for Microsoft Windows that allows users to automate repetitive tasks. It is driven by a scripting language that was initially aimed at providing keyboard shortcuts, otherwise known as hotkeys, that over time evolved into a full-fledged scripting language.

310 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
8
votes
1answer
784 views

automate so that if and only if external monitor is attached, closing laptop lid does nothing

Please don't mark as duplicate before reading the whole thing. I have read the other posts and they do not solve my issue. I'm using a laptop with an external display. When the display is connected, ...
6
votes
2answers
2k views

Windows virtual desktops. Cycle back to first desktop at end

Let's say I have three virtual desktops. I know I can navigate through them using: ctrl + windows + left | right However, is there a way to make it cycle back through to the beginning if I reach the ...
4
votes
0answers
497 views

I Need to Keep a Window Active

I need to keep a browser window active while I use another window. "Keep-on-Top" is not what I'm looking before because when I switch pages, it still goes inactive. I'm trying to keep a page ...
4
votes
1answer
693 views

Switch any program to kiosk mode

Sometimes friends or even unknown people visit me and we are doing something on my computer. I often find myself in the situation when I want to leave the computer but I don't completely trust the ...
3
votes
0answers
54 views

How can I recover an autohotkey script that has been over-written

I have an autohotkey script that is continuously running on my computer. I inadvertently saved a blank script over it, but the original is still running in the background. I tried to recover the ...
3
votes
0answers
696 views

Is there any way to type the clipboard to the guest in VMware

Similar to this question for VirtualBox: How do you auto-type the contents of the clipboard from the host into a guest Virtual Box instance? Is there any way to type the contents of the clipboard to ...
3
votes
0answers
394 views

AutoHotKey: Odd window sizing behavior on Windows 10

I realise this is probably a really obscure problem but hey it's the internet. I have a 24" portrait monitor, and I wanted vertical snapping. I found an online script, but for most types of windows, ...
3
votes
1answer
2k views

Custom Syntax Highlighting for AutoHotkey in Notepad++

I'm using the latest version of Notepad++ as of this post (version 7.3.3, 64-bit) with User Defined Language v.2.1.0.12. I've added syntax highlighting for AutoHotkey provided by the AHK message ...
3
votes
0answers
777 views

Monitor file change in AutoHotkey without a loop or timer

I am interested in having an .ahk file reloaded automatically whenever it changes. The reason is that I am hosting my .ahk files in Google Drive, and so the script may be changed on a running computer ...
3
votes
0answers
216 views

Get value for `Position` property from a Delphi TProgressBar class instance using AutoHotkey (ahk)

I would like to obtain the current Position (progress) property value from TProgressBar1, which is a child of TProgressFrame1 and grandchild of TPanel1 within a particular TProgressDlg Window. ...
3
votes
2answers
2k views

How to make AutoHotkey automatically close a pop-up dialog?

Question I'd like AutoHotkey to automatically detect when a certain pop-up dialog appears and take certain actions. How do I do that? Concrete example In my particular case, I'd like AutoHotkey to ...
2
votes
0answers
23 views

Holding Shift and Click solution

I`m trying to make a simple macro shift and left click are hold for 20 sec and durring that time another key is in the loop for this 20 sec. Seems like after shift and click are down nothing else i ...
2
votes
1answer
40 views

Prevent Winkey + Alt + Enter from opening Windows Media Center and rebind it

I've bought a new remote control and am using AHK to rebind some of its buttons. It doesn't have a software to set what each button will do, "it just works". Using KeypressOSD.ahk I'm able to see ...
2
votes
1answer
4k views

How can I disable "Do you want to open or save this file?” prompt for .mp3 files in IE 11?

I am using IE11 for my AutoHotKey scripts.I want to disable “Do you want to open or save this file?” download prompt. I tried following things. 1-)Find the correct registry value for.mp3 C:\Users\q&...
2
votes
0answers
221 views

Windows 7: Task Scheduler/Engine reduces the Working Set/memory of applications, is there anyway to stop this?

I've been trying to auto-start some Auto-HotKey scripts using the Task Scheduler since it allows the scripts to run with admin privileges without a UAC prompt. Usually, the scripts fail after several ...
2
votes
0answers
848 views

Set Scaling of individual applications in Windows

I occurs to be that I want any app I'm not looking at to be scaled down (to say 100%), but the one in focus to be scaled up (to 200%). This would both make maximal use of my hi-res laptop screen for ...
2
votes
1answer
834 views

How to edit/change/modify the Syntax Highlighting Color in VS Code

How to edit/change/modify the Syntax Highlighting Color in VS Code, ie for Autohotkey and/or Markdown languages? For example: Im using the High Contrast theme (black background), and in that theme, ...
2
votes
0answers
143 views

How to prevent window popup when new program starts?

Say I launch Firefox when reading a PDF. To prevent distraction, I want it to open silently until I manually switch to it. Is there a way to do this? All the search result I found is about JavaScript ...
2
votes
1answer
2k views

AHK is possibe to make this script works in inactive window

Is it possible to make this script work in a specific inactive/minimized window. ? loop { dllcall("keybd_event", int, VK, int, SC, int, 0, int, 0) dllcall("keybd_event", int, VK, int, SC, int,...
2
votes
1answer
342 views

Remap of Browser_Home key fails when browser window is not in focus

I have a bluetooth remote with a Browser_Home key, which I'm attempting to remap with AutoHotkey on my Windows 10 machine. By default, pressing Browser_Home does one of two things: If the window in ...
2
votes
0answers
366 views

Are there any other modifier keys on Windows?

I'm trying to use the Win key as a modifier key on Windows. So far, the best approach I found is to map it to another key using AutoHotKeys. For example, I can map the left win key to the left control ...
2
votes
0answers
954 views

Windows 10 Volume Mixer fails to keep System Sounds muted over Remote Desktop Connection

The problem: after having muted the System Sounds on the remote desktop machine, it shall unmute itself after several seconds. This pattern is persistent. The physical setting: I use my laptop at ...
2
votes
0answers
2k views

Passing control hotkeys to VirtualBox with AutoHotKey

I use VirtualBox on Windows 10 host, and my guest OS is linux openSUSE. Since I still need many windows control hotkeys, I do not use Auto Capture Keyboard in VirtualBox. As a drawback, I can't use ...
2
votes
1answer
959 views

Autohotkey: Use Appskey as modifier, suppress context menu

AppsKey & t:: Send Test This prints 'est' and opens the menu. I would like it to print 'Test' and to not open the menu.
2
votes
1answer
575 views

Shift+Ctrl+Tab not working in chrome with mapped Caps Lock key in Windows using SharpKeys

As suggested by this post, I used SharpKeys to map my Caps Lock key to Ctrl. A weird problem is that while other functions using this Caps Lock key as Ctrl works fine(like Caps Lock+Tab works fine in ...
2
votes
1answer
2k views

In AHK, how can I create a new Chrome browser window and activate it

I would like to create a new Chrome window with the following AutoHotKey script: #c:: Run, "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" "--profile-directory=Default",,,PID ...
2
votes
1answer
587 views

re-mapping media keys on a USB keyboard

Is it possible to re-map the media keys (volume, reload, etc) on a USB keyboard so that the order matches the one on my laptop? I want to re-map ONLY the ones on the USB keyboard. I've tried ...
2
votes
1answer
63 views

Open link at cursor position with keyboard shortcut

I'm using a rich web application that replaces my browser's right-click context menu with a menu of custom options. I want to be able to open a link in a new tab and right-click doesn't work for the ...
2
votes
0answers
307 views

How to use Windows key in Autohotkey as part of a macro

I have been using autohotkey on a terminal with 122 keys. I remapped the keys so that their original funky uses are now much closer to normal modern computers. I also mapped a scancode to Windows ...
2
votes
1answer
957 views

AutoHotkey: While 2 keys are pressed = press 3rd key?

In AutoHotkey, how can I do the following: While Space and W are pressed down at the same time, send LShift every X milliseconds; do this until Space and W both are released. I'm a beginner; what I ...
2
votes
2answers
4k views

How can I return focus to the previous window?

I have an Autohotkey script which opens and closes a pop-out command line similar to the Quake console dropdown. When I close it, however, it places focus on the taskbar. How can I instead return ...
2
votes
1answer
334 views

Refining an AutoHotkey script

The purpose of this script is: The first two rows of hotkeys always effective. The remaining hotkeys work at NO TEXT INPUT Status only. In other words, when the small vertical lines are flashing ...
2
votes
1answer
551 views

Autohotkey AppsKey does not work properly in Chrome

I try the following hotkey in Chrome: !F3::Send {AppsKey}{Up} Chrome opens the context menu but it doesn't move the selected line in the context menu. Instead the {Up} command moves the scroll bar ...
2
votes
2answers
169 views

Detection of Objects on Remote VM, like start button, cmd prompt using hotkeys

I am able to take remote control of any virtual machine using AutoHotKey . I want to run ipconfig command on remote machine. It can be performed using mouse clicks, but I want to do it using keyboard ...
2
votes
2answers
251 views

AHK macro automation software: GUI does not show

I remember in the past I have used AHK to do some repetitive task. I did it via some GUI; it recorded my mouse gestures and my keyboard strokes. I have downloaded it again but now I see no GUI, just ...
2
votes
1answer
2k views

Difficulty with middle click - MS Wireless 6000 scroll wheel sensitivity

(Microsoft Windows) When I try to middle click on the scroll wheel, I usually just get a little bit of scrolling instead. I am using the Microsoft Wireless Laser Mouse 6000, which is very ...
2
votes
2answers
79 views

How to remap Enter as a right control modifier in Win 8.1?

I did this with keyRemap4macbook on OSX. Enter alone works as Enter but Enter+Key becomes Ctrl+Key. How do I do this in Windows?
1
vote
0answers
24 views

How to map NumPad1 to Alt+Enter?

I'm new to AutoHotKey, and I'm trying to map NumPad1 to Alt+Enter. I have done this by right clicking on the AHK window and editing script, which is in My Documents/Autohotkey.ahk and overwriting the ...
1
vote
0answers
17 views

AutoHotkey; using a modifier as a normal key and then as modifier

Novice on AHK here. Here are the lines: ^Alt:: Send, b ^!PGDN:: Send, r The "^!" part of the second line gets send continuously before PGDN is pressed, and I get something like "bbbr", so I have ...
1
vote
0answers
37 views

How to highlight focussed window using bug.n

I'm using bug.n which is based on autohotkey for my window manager on Windows 10 and want the window with current focus to be obvious by having a coloured border like the top left window in the image ...
1
vote
3answers
458 views

How to bind F13-F24 keys to the 12 side buttons on Razer Naga?

I'm trying to use the Razer Synapse configuration app to bind the 12 number buttons send extra F keys from the 13..24 range, but I'm not having any progress. When I'm in the right menu, I can press F1 ...
1
vote
0answers
475 views

autohotkey script to bind multiple key-presses to one key

^y:: y + & 6 return On pressing control+Y I want the actions of: y^6 to be pressed on the keyboard. The above doesn't work. I can't find where it says in any documentation or tutorial how ...
1
vote
0answers
165 views

AHK says invalid hotkey

My AHK script says that numpad3 or 3 is invalid, what is the code I must input to make my script input numbers? F9:: Toggle := !Toggle While Toggle{ 3 sleep 10 4 ...
1
vote
0answers
44 views

Media Keys for Specific, Uncommon media sites?

I like listening to an old-style radio show called Adventures in Odyssey. It's absolutely awesome, and the site is well made except for a few things. The player automatically continues to the next ...
1
vote
0answers
216 views

A program won't come to the foreground (Windows 10)

I have a program (QGIS, which uses QT5) that will not come to the foreground. It starts maximized (that's fine) but it stays behind all my other programs. It can be focused, and I can work in QGIS, ...
1
vote
0answers
91 views

How to execute a host autohotey combination/script from within VMware VM?

I have: Deepin OS as a VM in VMware workstation pro 15 Windows 10 as my main OS A script at my main OS so that when I click left control + left arrow / right arrow, it switches between workspaces ...
1
vote
0answers
42 views

Hotkey to play selected folder/s on windows explorer

If one or more folders on windows explorer are selected and then "Alt + Intro" is pressed, windows shows the properties of those folders. I would like to make a custom hotkey to play the files in the ...
1
vote
1answer
298 views

How to let an Auto-Hotkey Script survive desktop-locking?

I got an Auto-Hotkey script #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. #Warn ; Recommended for catching common errors. SendMode Event ; Input worked ...
1
vote
1answer
249 views

Autohotkey script for releasing a key after being pressed in combination with another

Does anyone know what the script would be to release left after I press left and down? I want it so that when I press and hold ← ↓, ← releases but ↓ continues to be pressed.
1
vote
1answer
991 views

Three Key combination for AutoHotkey

I found out how to remap Caps Lock and S to something else: CapsLock &:: ... But how can I have a combination with three keys like CTRL, ALT and S?