How do I use UTF-8 in AutoHotKey?
The .ahk text file needed to be saved with UTF8-BOM encoding rather than UTF8 As pointed out in this comment, posting as an answer for more visibility.
The .ahk text file needed to be saved with UTF8-BOM encoding rather than UTF8 As pointed out in this comment, posting as an answer for more visibility.
Alright; The answer seems to be: ^q:: Input Key, L1 if Key=f …some code here… return
Simply add a shortcut of your script in the Windows ‘Startup’ folder. Three ways to get there: 1– In Windows Explorer, go to %APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup (for current user startup list) or %ALLUSERSPROFILE%\Microsoft\Windows\Start Menu\Programs\Startup (for every user startup list) or 2– Open Windows’ Run application (Windows + r) write shell:startup (current user) or shell:common startup (every … Read more
Thanks to jNizM for their helpful guide on the AHK forums. Setup Notepad++ for AutoHotkey Syntax-Highlighting Download userDefineLang_AHK.xml as raw (Right-click and choosing save as target…) Start Notepad++ and click on Menu Language -> Define your language Click Import… and select the file you downloaded in step 1 Restart Notepad++ Default Theme (Preview) Lazy Theme … Read more
Add an emergency exit hotkey The most reliable method of ending an active script is to pre-emptively include an emergency ExitApp hotkey. A common practice is to place the following at the bottom of any script. Esc::ExitApp ; Exit script with Escape key You can also set hotkeys to pause, suspend, or reload your script. … Read more
Thank you all for answers. I was unable to solve this using AutoHotkey — PhilLho’s answer was close, but I really needed exatly the same behaviour as with left Alt key. However, the registry thing actually worked as I needed. Save this as AltGR_to_LeftAlt.reg file and run it: Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout] … Read more
Aha! I’ve figured it out. If ahk and the target app are not running under the same privileges (or user) ahk won’t intercept/simulate keyboard events properly. In my case, visual studio was run with administrator (elevated) privileges while the ahk script was run as the currently logged on user. Either of the following solved the … Read more
I think AutoHotkey’s GUI implementation is easier to use like many of its commands. AutoHotkey (no longer maintained) has 3 forks : AutoHotkey v1.1.* (previously known as AutoHotkey_L) has COM, Unicode support, object-oriented -like syntax, arrays, and more. AutoHotkeyCE works on Windows mobile PDA’s and smartphones (unfinished, no longer maintained). IronAHK, a .NET version of … Read more