Anyone who’s taken advantage of their office application’s macro function will realise just how useful a tool it is: suddenly, instead of having to perform several repetitive tasks or mouse clicks over and over again, you can record those keystrokes or mouse clicks, then “play” them back with a single click or keystroke, saving you time and effort in the process.
The only problem with macros is that they’re limited to Office, so what can you do if you’d like to extend this functionality to another program – or across Windows as a whole? The solution lies a program called AutoHotkey. This allows you to create scripts that can automate not just common commands like launching programs, but also mouse clicks and keystrokes. It can also be used as an auto-text tool, to create customised entry forms, dialogue boxes and menu bars, and remap keys and buttons on mice and joysticks for good measure.
Scripting for most of these is done by hand in AutoHotkey’s editor, but mouse and keystrokes can also be recorded using the supplied macro recorder (AutoScriptWriter), just like in Office. We’ve found it’s more effective to record keystrokes rather than rely on mouse clicks as these are based on the mouse’s position on the screen, which means they won’t work if a dialogue box or program window is resized or moved.
AutoHotkey itself hasn’t been developed since 2009; it’s effectively been superseded by a variant called AutoHotkey_L, which is in active development. This adds several new features for more advanced users, but crucially for the average Joe has dropped the macro recorder (the help file points people towards a script to replace this feature). For most people, however, AutoHotkey is perfect for automating just about any task in Windows or a third-party program.
AutoHotKey 1.1.19.02 brings these changes:
- Removed the 16-color icons which were used on Win9x/Win2k.
- Removed the separate tray icon resources.
- Improved selection of icon size when loading icons from DLL/EXE files.
- Fixed some issues with hotkey validation at load time.
- Fixed /iLib switch to write the file even if there's a syntax error.
- Fixed return/break/continue/goto in try..finally.