Free AutoHotkey Scripts and Apps for Learning Script Writing and Generating Ideas
* * *
The Why AutoHotkey? book for Kindle Free on Amazon!
AutoHotkey Script Download Index
(Click script or app name to jump directly to description and download.)
There are a few changes which makes this page preferable for downloading scripts. In additions to adding descriptions for a number of the newer scripts, links have been added for directly downloading files from this page. In most cases, there is a ZIP file comtaining the files, but occasionally only the AHK file is posted—in which case there is no ZIP file.
I have added links for downloading only the AHK files. Since they only contain text (AutoHotkey code), they should not set off any security alarms on your computer. Now there is no need for people to download any EXE files.
It's a long page so for quicker access use the download index to the script names.
* * *
AutoHotkey Script Roundup by Jack Dunning (Update June 22, 2016)
Note: Get an introduction to AutoHotkey with the overview e-book, AutoHotkey Tricks You Ought to Do with Windows FREE!
May 2017: For Amazon Kindle owners, download the AutoHotkey Tricks book FREE at Amazon.com and worldwide Amazon sites. Also, available FREE at Apple iBooks (worldwide), Barnes and Noble Nook Books, and Kobo Books (click flag at top of page for worldwide availability).
If you've never heard of AutoHotkey and wonder what all the brouhaha is about, here is a short "Introduction to AutoHotkey" for newcomers.
One of the best ways to learn how to write scripts is to see how others do it. Whenever I give an example, I usually offer a practical use for the snippet. That way people not only learn how the code works, but they start to see how AutoHotkey will be useful to them. Over the course of the last few years I've posted AutoHotkey scripts (free to download and use) which accomplish a variety of different tasks. Some are as simple as a one-liner which will make any window "always-on-top" while others (although not complicated) involve time calculations for the age of grandkids (or anyone) or a barebones music player. The following are a few of the practical uses found for download:
• Adding dates to any documents (AddDate)
• Instant correction of commonly misspelled English words (AutoCorrect)
If you want to do more with AutoHotKey AutoCorrect and HotStrings, a series of blogs on "Beginning AutoHotKey HotString Techniques" are available at Jack's AutoHotKey Blog:
• Quick backup of text (BackupText and IncrementalSaveText)
• Calculating ages (GrandKids)
• Opening hard to find or often used folders (FolderOpen)
• Setting up temporary hotkey combinations to add text to documents (InstantHotkey)
• Tailored Start pop-up windows and menus as a replacement for the missing Start Menu in Windows 8 or any other version of Windows (LaunchWindow and QuickLinks)
• A barebones Windows media player for music and video (QuikPlay)
• A reminder app that pops-up for appointments (Reminder)
• A voice app that reads text to you (SayWhat)
• An app for moving and sizing options for the last active window (WindowMove)
• An app for looking up the geographic location of any highlighted IP address on the Web (IPFind)
• And more!
I have posted these scripts at the ComputorEdge AutoHotkey download site. This page is my shot at documenting the purpose of the various scripts. Previously, anyone that went to the download site for the first time might be overwhelmed with the number of downloads with no clue (other than the filenames) as to their function. For that reason I'm creating this page which quickly explains the purpose of each posted script. I will endeavor to keep this Web page up-to-date, as well as, the same documents on the download site under the name "_AutoHotkey_Script_Index" in various formats including TXT, PDF, EPUB and MOBI (for Amazon Kindle).
Note: For the convenience of people learning AutoHotkey, most of these scripts and their associated articles have been updated, organized, and included in the AutoHotkey e-books available at ComputorEdge E-Books. These books start at a beginning level and progress in order to intermediate script writing. A Beginner's Guide to AutoHotkey is for the complete novice with no programming experience. Digging Deeper Into AutoHotkey builds on the concepts and commands introduced in the beginning book. AutoHotkey Applications is an intermediate level book with particular emphasis on the pop-up window type controls called GUIs (Graphical User Interface) built into AutoHotkey. (Many of the GUIs are shown as images in this page.) The most recent e-book is A Beginner's Guide to Using Regular Expressions in AutoHotkey, Exploring the Mysteries of RegEx which is NOT a beginning AutoHotkey book, but a beginning Regular Expression book for intermediate and above AutoHotkey users.
Other than possibly sparking ideas, experienced script writers and programmers should have no problem teaching themselves AutoHotkey from the excellent online documentation without any help from these books. (If you would like a peek into the contents of the books, the Table of Contents and Indexes from each of these books is included in the e-book, AutoHotkey Tricks You Ought to Do with Windows. Get a FREE copy in your preferred format at ComputorEdge E-Books.) These e-books are also available at Amazon for the Kindle.
All of these scripts were written for educational purposes. I don't consider any of them truly complete and you are free to use any of them with or without giving me credit (or blame). While there are many scripts posted, there are even more of my examples which only appear in the individual columns (and of course the e-books currently available).
For files ending with the AHK extension (e.g. AddDate.ahk) to run, the main AutoHotkey program needs to be downloaded and installed. The AHK files are scripts saved in text files and are safe for downloading and opening with any text editor. If you want to learn how to use AutoHotkey, you can use the AHK files as examples. All script development and most testing is done with AHK files. It is safe to download any of the files on this download page, but as a rule AHK files are safe since they only include text.
If warranted, either as a demonstration or a free app for non-AutoHotkey users, many of the AutoHotkey AHK files have been compiled into executable (EXE) files which will run on any Windows computer with or without AutoHotkey installed. This makes the scripts completely portable. As a rule it can be a bit tricky (and sometimes dangerous) to download and run EXE files. Since a double-click on a downloaded EXE file runs directly on any Windows computer, this is a common way for people with bad intentions to spread malware. However, I can assure you that I have written and compiled every one of these files and they are completely safe (99.9%) to download and run.
What I can't guarantee is that our download site will never be hacked, thus allowing dangerous EXE files to infect the site (this is a potential problem for any download site anywhere), I think this type of security breach is extremely unlikely to happen (although stranger things have happened). The only way to be truly safe is to download the AHK file and compile it into an EXE file yourself. Or better yet, copy-and-paste the code from the books or articles I reference in this list directly into your new AHK scripts.
Note: AutoHotkey is an offshoot of the free Windows utility language AutoIt. While both are very similar in features and capability, there are significant differences in both form and function. For more information see the Web page "AutoHotkey Versus AutoIt: A Comparison and Review of the Free Windows Scripting Languages".
(Click script or app name to jump directly to description and download.)
ComputorEdge AutoHotkey Scripts
• Accents.zip containing Accents.ahk and Accents.exe
This little Accent app from Skrommel will come in handy if you work with foreign languages or want them for the few English words that ask for them. Since these special characters don't appear on most keyboards Accents makes is much easier to add various types of squiggles to your documents. (See image at right. The image is an animated GIF file. Most media will show it in action, but some, such as the Amazon Kindle e-book, will not.)
Note: While a clever use of the Input command, in its current form Accents.ahk interferes with other Hotstrings. We've added a Suspend option to the System Tray icon right-click menu which we recommend when the app is not needed. Perhaps the use of a Hotkey to temporarily activate the routine or a pop-up menu would work better without blocking other active Hotstrings.
• AddDate.zip containing AddDate.ahk and AddDate.exe Updated the MonthCal GUI to deal with common AutoHotkey error and combining with other scripts included in the book A Beginner's Guide to AutoHotkey. Two hotstrings included in the AutoHotkey Applications e-book.)
AddDate is a demonstration script for adding dates to documents. When loaded, the script uses four different methods demonstrated with hotkey combinations:
CTRL+WIN+F1 => The datetime stamp (i.e. 20130628103349)
CTRL+WIN+F2 => The date using the FormatTime command (FormatTime, TimeString, %A_NOW%, MMMM d, yyyy)
CTRL+WIN+F3 => The date using built in variables (%A_DDD%, %A_MMM% %A_D%, %A_YYYY%)
CTRL+WIN+D => The MonthCal GUI pop-up calendar (Gui, Add, MonthCal, vDayPick)
Anow => Instantly add today's date formatted (September 7, 2013)
Adate => Activate MonthCal GUI pop-up
• AddressBook.zip containing AddressBook.ahk and AddressBook.exe Included in the AutoHotkey Applications e-book.
This example of a ListView GUI keeps a database of names and addresses. It initiates e-mail, inserts name and address into documents, and calculates ages. A personal address and data book which uses AutoHotkey ListView to display entries. Right-click on entry to send e-mail, insert the address in any document, or calculate ages.
Always_on_Top.zip contains Always_on_Top.ahk and Always_on_Top.exe Included in the book A Beginner's Guide to AutoHotkey
Always_on_Top is a one-line script which toggles any active window always-on-top with the hotkey combination CTRL+WIN+F8.
^#F8::WinSet, AlwaysOnTop, toggle, A
See this Beginner's AutoHotkey TIp about always-on-top at Jack's AutoHotkey Blog.
In addition, three additional Hotkeys have been added to the Always_on_Top.ahk script for making a window transparent.
CTRL+WIN+F9 for semi-transparent
CTRL+WIN+F10 for opaque
CTRL+WIN+F11 for a menu of four levels of opaqueness
See this additional Beginner's AutoHotkey Tip discussing the above window tranparency Hotkeys at Jack's AutoHotkey Blog.
• AutoCorrect.zip contains AutoCorrect.ahk and AutoCorrect.exe included in the e-book Digging Deeper Into AutoHotkey
This slightly modified AutoCorrect.ahk script is from the AutoHotkey Download Web site. It corrects many commonly misspelled English words instantly in any Windows program or Web editing page. See "Add AutoCorrection to All Your Windows PC Programs with AutoHotkey."
• AutoHotkey Quick Reference
The AutoHotkeyQuickRef.ahk script uses a hidden index found in the AutoHotkey.com site which quickly finds and loads pages for commands, functions, variables, and other AutoHotkey details. (Previous script dated December 3, 2016)
The latest version requires the use of an AHKRef.ini file for formatting search terms to locate built-in AutoHotkey variables. (The INI file should be placed in the same folder as the AutoHotkeyQuickRef.ahk script
This script downloads the source code for the page and currently displays the syntax for commands and functions in a message box or loads pages for recognized variables and details in the default browser. If not found, a site search for the term automatically loads. Discussion of this reference tool can be found at Jack's AutoHotkey Blog.
• AutoHotkey Orig.zip included in the AutoHotkey Applications e-book.
This ZIP file contains the original AutoHotkey download with utilities no longer available with the current download of AutoHotkey_L—specifically AutoScriptWriter.
• AutoHotkeyControl.zip A control center for starting and stopping various independent AutoHotkey scripts, plus dropdown menu to use features in each script. (Included in the AutoHotkey Applications e-book.)
The AutoHotkeyControl.ahk script file and image files are included in the ZIP file.
• BackupText.ahk included in the e-book Digging Deeper Into AutoHotkey
The BackupText script copies selected text to a text file in the user's Documents folder in a file named SaveEdit.txt. Each time the CTRL+ALT+B hotkey combination is used, all the text in the document or Web editing field is selected, copied to the Windows Clipboard, then saved to the SaveEdit.txt file. This is only for quick, temporary backup of current unsaved work. The old file is overwritten each time the routine is used. To do incremental backup for text see IncrementalSaveText.ahk below.
• CalorieCount.zip containing CalorieCount.ahk and CalorieCount.exe Included in the AutoHotkey Applications e-book.
This AutoHotkey script keeps a daily log of calories consumed. It includes a special feature for importing specific food calories directly from the Internet.
• ChangeCase.zip contains ChangeCase.ahk and ChangeCase.exe included in the book A Beginner's Guide to AutoHotkey
When loaded the ChangeCase script sets up hotkey combinations which change the case of selected text:
CTRL+U => Change selected text to all upper case (StringUpper)
CTRL+L => Change selected text to all lower case (StringLower)
CTRL+SHIFT+U => Change selected text to all words with an initial capitalized letter (StringUpper with the parameter T)
• CheckStyles.ahk is a script by djcpal1 which displays selected WS_XXXX and WS_EX_XXXX window styles for any window under the hovering mouse cursor. Useful for developing an understanding of how to manipulate an open window with the WinSet AutoHotkey command. See more about CheckStyles.ahk at Jack's AutoHotkey Blog.
• clipbrd.zip includes clipbrd.exe which is a handy Windows Clipboard viewer which was included with older versions of Windows. This is included for anyone who wants to restore it to their Windows machine.
While it's easy enough to view text in the Windows Clipboard with an AutoHotkey MsgBox, images are a little more complex. The ClipBook Viewer (clipbrd.exe) makes it easy to view images in the clipboard. See "Peek Inside Windows Clipboard (Beginning AutoHotkey Tip)" and "Peek Inside Windows Clipboard, Part 2 (Intermediate AutoHotkey OnClipboardChange Tip)" for more information.
• CopyRef.ahk acts as a reference collection tool for any research work. Highlighted any text on any page or in any document copy to a blank Notepad window with the CTRL+ALT+C Hotkey combination. If not already open, the script launches and displays an "Untitled" Notepad window. After that, whenever executing the Hotkey combination, the app continues to collect new selected text in the same Notepad window without activating that window—even if minimized. This saves the repetitive copy-and-paste routine while switching between windows.
This script was written with students in mind for the "Why AutoHotkey for Students?" blog, but of course, anyone is free to use it. CopyRef.ahk represents a much more robust version of the original SaveText.ahk script used to copy selected text to ScratchPad by Desi Quintans. In addition to a number of additional protections, the CopyReg.ahk script uses the standard AutoHotkey Clipboard routine, plus, the Control, EditPaste command for greater speed and reliability. However, for the Control, EditPaste command to work, it must send text to an EDIT control.
• CPULoad.zip contains CPULoad.ahk taken from the CPULoad AutoHotkey forum topic, the compiled CPULoad.exe, and the XGraph.ahk AutoHotkey graphing utilities for real time data plotting. Posted by SKAN on the autohotkey.com forum, XGraph is a set of AutoHotkey tools which enable graphing as demonstrated by CPULoad.exe.
If you want to make graphs with AutoHotkey, XGraph is one way to do it. (Another set of graphing tools is BarChart posted by Learning one. I've played around a little with BarChart and plan to discuss it sometime in the future.)
I've included CPULoad here because it is a quick loading gadget that can be used without any knowledge of AutoHotkey. I compiled the AutoHotkey script into an executable file (EXE) which will run on any Windows computer. If you want to use it without modification, then download CPULoad.zip from the ComputorEdge AutoHotkey download site. Extract the file CPULoad.exe and double-click to load it. (No AutoHotkey required!)
If you want to tinker with the script, then both CPULoad.ahk and XGraph.ahk (the required #Include file) are found in the same CPULoad.zip file.
• DateMenus.zip contains DateMenus.ahk discussed in Chapter Thirteen, Fourteen, and Fifteen of Beginning AutoHotkey Hotstrings.
This AutoHotkey Hotstring example offers three different methods for insert times and dates into any document. Each uses the word "date" followed by a different punctuation mark (hyphen -, semicolon ; or close square bracket ]). The variable A_End_Char stores the Hotstring activating character and launches the appropriate subroutine. When A_End_Char is a hyphen ( - ), the menu shown at right pops-up. The semicolon ( ; ) launches the MonthCal GUI and the close square bracket( ] ) pops up the DateTime GUI.date
Tip: Chapter Fifteen includes a technique for tracking the original active window which helps locate the right window for inserting the date after opening a GUI pop-up.
• Dictionary.ahk included in the AutoHotkey Applications e-book.
[Sorry, but the Dictionary scripts seems to no longer work. Something probably changed on the Dictionary.com page and as far as I know there is no update. That's the problem with scripts that depend upon automatically pulling data from Web pages. If anyone takes the time to fix it, please let me know.]
This general purpose AutoHotkey app is the instant definitions script posted at the AutoHotkey Web site by Robert Ryan (rbrtryn). It has several advantages over the usual Web search for dictionary definitions, but best of all it's fast. This script accesses Dictionary.com to look up either a word entered into a pop-up (CTRL+SHIFT+D) or a word selected (click and hold left mouse button while dragging to highlight the word) in any window (CTRL+ALT+D) whether a text editor, Web page, or any other program with select-able text.
• EggTimer.zip contains EggTimer.ahk and EggTimer.exe included in the AutoHotkey Applications e-book.
The EggTimer app works by opening a window (after loading, press CTRL+F12) where you set the desired time interval, then click Start (see Figure 1 at left). The time counts down to zero in the edit windows while a progress bar works it way from left to right. Once the countdown increments to zero, a bell rings, the computer voice says "Your eggs are ready!", and a window pops up with the same message. Now you have the perfect soft boiled egg.
• FavoritesFolder.zip contains FavoritesFolder.ahk and FavoritesFolder.exe included in the Chapter Two of AutoHotkey Applications e-book.
With FavoriteFolders (link to original script) I can use the hotkey combination CTRL+ALT+E to pop-up a menu of those same Favorite links in Windows Vista, Windows 7, Windows 8,or Windows 10 when opening/saving a file. The location of that folder which contains the shortcuts is C:\Users\%A_UserName%\Links. (The original AHK script uses the middle mouse button for the hotkey which didn't work for me. I changed it to CTRL+ALT+E. Plus, the file could not be compiled since it referenced itself for the list of menu items. I modified this Easy Access Folders script to use the new key combination and the Favorites folder for the pop-up menu.
• FolderOpen.ahk included in the book A Beginner's Guide to AutoHotkey.
When loaded FolderOpen sets up sample hotkey combinations for hard to find or often used folders and an example AutoHotkey Help window as follows:
CTRL+WIN+S => Open the Startup folder
CTRL+WIN+P => Open the Programs folder
CTRL+WIN+I => Open the My Pictures folder
CTRL+WIN+T => Open the SendTo folder
CTRL+F12 => Open a Help window for these options
• GooglePhraseFix.zip and GooglePhraseFix.ahk included in the Chapter Nine "Stealing AutoHotkey Scripts" in the free e-book AutoHotkey Tricks You Ought To Do With Windows.
This is a clever little "Autocorrect Anything" script posted on the AutoHotkey forum by aaston86. The script I assigned the name GooglePhraseFix.ahk uses Google search to correct selected phrases by accessing the "Showing results for/Did you mean:" line in a Google search results page. While not always consistent, it is amazing how often it works.
• GrandKids 5.ahk, GrandKids 6.ahk, GrandKids 7.ahk and GrandKids.ini included in the Digging Deeper Into AutoHotkey e-book.
This particular script went through some evolution due to the problems caused by calculating dates and time spans. (In my defense, I saw a response in the AutoHotkey Forum, from someone who has many more years experience and much more expertise than I do, make a pretty basic date calculating mistake by trying to directly subtract date/time stamps.) GrandKids is an app which reads an INI data file with the birthdays of grandchildren (or anyone), calculates how old they are, then displays the information in a pop-up window.
The first two versions (GrandKids 5.ahk and GrandKids 6.ahk) launch the pop-up immediately when the GrandKids app is loaded. They require reloading from the System Tray to display again. The last version (GrandKids 7.ahk) uses the hotkey combination WIN+G to open the pop-up. Three chapters in the e-book explain the evolution of the script. These chapters are included as one section of the e-book Digging Deeper Into AutoHotkey.
• HideWindow.zip with HideWindow.ahk included in the chapter on "Stealing AutoHotkey Scripts" in the e-book AutoHotkey Tricks You Ought To Do With Windows.
The AutoHotkey script I call HideWindow.ahk was found on the AutoHotkey scripts page. (I'm not sure who originally wrote it.) This HideWindow app quickly makes a window disappear, WIN+H (+H), and even removes the active Taskbar icon making it almost impossible to find the hidden window. It's not minimized, but hidden. Great for hiding inappropriate activities from the boss. The hidden window continues to run the program (whatever it is) in the background. Right-click on the AutoHotkey icon in the System Tray and select if from the menu to bring it back.
• ImageList.zip included in the AutoHotkey Applications e-book.
The AutoHotkey app ImageList.ahk and ImageList.exe displays (at left) the icons in SHELL32.dll along with the image number, shown in image at left. This is useful for finding icons available on Windows computers to add to GUIs, Menus, the System Tray.
• IncrementalSaveText.zip contains IncrementalSaveText.ahk and IncrementalSaveText.exe Discussed in Chapter Fifteen of the Digging Deeper Into AutoHotkey e-book.
The IncrementalSaveText AutoHotkey script saves the text from any window, including Web pages, by selecting the text, copying it to the Windows Clipboard, then saving it in a backup text file with the filename equal to the window title plus the current date and time in date/time format. The file is saved in the user's Documents/Backup folder. If the folder doesn't exist, it will be created. CTRL+WIN+ALT+B initiates the backup procedure once the script is loaded. (For one-time backup, see BackupText.ahk.)
• InstantHotkey.zip contains InstantHotkey.ahk and InstantHotkey.exe, and included in the AutoHotkey Applications e-book.
The InstantHotkey script quickly sets up hotkey combinations temporarily for adding repeated and/or long lines of text to any current Windows document or Web editing field. This is handy for those situations where you know that you will be using a particular term or set of terms a number of times. The window to set up the hotkey opens immediately when the script is loaded. After the combination is set, it can be changed by right-clicking on the icon in the System Tray and selecting ShowHotkey. Hovering over the same icon will display the current hotkey combination setting.
If your security setting makes it difficult to download the EXE file, the same two files are also located in the InstantHotkey.zip file for easier downloading.
• IPFind.zip contains IPFind.ahk and IPFind.exe It's an app which demonstrates the use of Regular Expressions (RegEx) in AutoHotkey by finding the geographic location of an IP address. First the IP (or group of IPs) is extracted from any Windows program. Next, each IP is looked up on the Web (without using a Web browser), then extracting and displaying the location(s) as shown by the image on the left. These techniques along with other applications for the RegExMatch() and RegExReplace() AutoHotkey functions are discussed in the e-book A Beginner's Guide to Using Regular Expressions in AutoHotkey.
• Jack Stuffed Cheeseburger Recipe: CheeseBurgerRecipe.zip contains CheeseBurgerRecipe.ahk, CheeseBurgerRecip.exe, and the icon file CheeseBurgerIcon.ico. This simple recipe script in its original form (CheeseBurgerRecipeOrig.ahk) uses the built-in Windows MsgBox to display the steps (Ingredients, Preparation, Cooking, and Serving) in successive pop-up windows. The individual steps may be selected from the System Tray icon right-click menu, then continuing through the remaining steps.
The latest version includes two new recipes: Animal-style Cheeseburger and Jack Stuffed Cheeseburger (Animal Style). The second new recipe uses the GoTo command to draw from the first two recipes to create a third. The right-click menu gets condensed by using submenus for the recipe steps.
Multiple windows can open simultaneously for repositioning through the right-click menu. Introduced in the blog "Why AutoHotkey for Dieticians and Chefs?" at Jack's AutoHotkey Blog.
• KeyPad.zip If you have a Windows laptop computer without a number keypad or want to use the click of a mouse rather than your fingers to punch numbers, then you're going to like this one. A person who goes by the forum name sveco has produced a short AutoHotkey script which places a number keypad on a Windows computer screen (see Figure below left). The beauty of this app is that it never takes the focus away from your working document. When you click on the keypad, it does not become active and will send the input to your last active window.
You can use it with any active window to input numbers or use the cursor keys. For the right person, this could be just the ticket. The only issues was that the keypad on a keyboard doesn't necessary sync with the pop-up, but if you don't have a keyboard numeric keypad, it's no problem.
You don't need to know AutoHotkey to use this app. I've compiled it and posted both theKeyPad.ahk and the KeyPad.exe files in a ZIP file at the AutoHotkeydownload site. Download the compressed ZIP file, KeyPad.zip and extract the EXE file. Double-click and the app loads. Click the little x in the upper right-hand corner to close the app.
AutoHotkey Notes for KeyPad
For people who are learning AutoHotkey (and you should be learning AutoHotkey if you don't already know it), there are a couple of features of note in this short script. The fact that the keypad is never active, yet is clickable has implications for other AutoHotkey scripts acting as control panels. The controls can innocuously sit on the screen until they are needed, yet even then they won't interfere with the active window. Let's look at how it's done. Let's look at how it's done.
The first line of code needed to produce this effect is:
Gui, +LastFound +AlwaysOnTop +ToolWindow +Border +E0x08000000With the exception of +AlwaysOnTop and +E0x08000000 most of these parameters are cosmetic and can be found in the GUI Options section of the online documentation. Naturally, the keypad must be always-on-top since it would be ridiculous for it to disappear behind other windows every time another window is clicked.
The second option +E0x08000000 is a little more cryptic. This parameter is part of the Extended Window Styles (WS_EX_NOACTIVATE 0x08000000L) built into Windows. It is called as an option in AutoHotkey GUIs by placing +E in front of the number. The +E0x08000000 option calls WS_EX_NOACTIVATE which prevents the window from activating when the user clicks on it. Yet, the window still intercepts the click.
The next line of interest is:
Gui, Show, x1350 y87 h260 w215 NoActivateThe NoActivate option prevents the window from becoming the active window when initially displayed. Between the two parameters (+E0x08000000 in the Gui command line and NoActivate in the Gui, Show command line), the windows is now clickable, always available and never active.
This little script could easily be made into a hotkey by adding the Gui, Show line of code to a hotkey combination somewhere after the auto-execute section of the script:
^!k::Gui, Show, x1350 y87 h260 w215 NoActivateBut you will want to remove the GuiClose: subroutine, otherwise the script will exit (ExitApp) anytime you close the window and the hotkey combination will be useless. (I added CTRL+ALT+K as a line in the AHK file, but the semicolon, which turns the line into a comment, must be removed. Don't forget to comment out the GuiClose label with a semicolon in front of each line.)
If you want a transparent keypad, then there are two lines in the code which merely need to be un-commented (remove the ; before each line).
This KeyPad app is yet another cool way to use AutoHotkey.
• LaunchWindow.zip contains LaunchWindow.ahk and LaunchWindow.exe discussed in Chapter Nineteen of Digging Deeper Into AutoHotkey.
The LaunchWindow script is a demonstration of how AutoHotkey can be used to build a tailored Start pop-up menu window for any version of Windows—including Windows 8. LaunchWindow uses the hotkey combination CTRL+WIN+L to open the pop-up. To tailor the contents of LaunchWindow the AHK script needs to be modified.
• Magnifier.zip contains Magnifier.ahk and Magnifier.exe included in the AutoHotkey Applications e-book.
What distinguishes this cool magnifier are its features. You can change the level of magnification by selecting the value in the upper left-hand corner menu. You can even reduce the size by half. This screen magnifier has adjustments for magnification, anti-aliasing (smoothing), and time delay.
• MousePrecise.ahk Discussed in a series of blogs about Hotkeys at Jack's AutoHotkey Blog and featured in the book AutoHotkey Hotkey Techniques.
The MousePrecise.ahk script converts the numeric keypad into a micro mover for the mouse cursor—one pixel at a time.
The GroupAdd command isolates the Hotkeys' availability to the graphics programs included in the group. As a summary script, it uses a number of commands and directives considered best practices for optimizing Hotkeys.
Forced expressions, toggles, and the ternary operator demonstrate how more power and flexibility can be added to almost any AutoHotkey command.
If you learn nothing else about Hotkeys and AutoHotkey commands, delve into the techniques explained in this series of blogs.
• Mute.zip contains Mute.ahk and Mute.exe discussed in Chapter Eight, "Making the Insert and Caps Lock Key Useful," of the e-book Digging Deeper Into AutoHotkey.
The Mute script is a sample script with one line of code which turns the CAPSLOCK key into an audio mute toggle button.
CapsLock:: SoundSet, +1, , mute
• NoHotkey.zip contains NoHotkey.ahk and NoHotkey.exe discussed in Chapter Thirteen of the e-book A Beginner's Guide to AutoHotkey.
The NoHotkey script is a sample script with one line of code which disables the hotkey combination CTRL+A while displaying a message box. This prevents accidental selection of all text which can then get inadvertently wiped out with a single stroke of a key.
• NumbersSpeak.zip contains NumbersSpeak.ahk, cow-skating.jpg (image file), and cow-madcow.wav (audio file). Discussed in the blog "AutoHotkey Scan Codes, Speech, Sound, and Splash Images in Children’s Apps."
The NumbersSpeak.ahk script uses the SayWhat.ahk script found below as a basis for exploring techniques in writing children's educational software. The script uses the SplashImage and SoundPlay commands, plus the ComObject function ComObjCreate("SAPI.SpVoice").Speak().
Press the letter "C" , and the script displays the SplashImage, reads the words, then spells "cow", followed by the sound of a laughing mad cow mooing.
While the script is far from complete, it features some of the AutoHotkey tools available for building cute children's scripts. It is an apt companion for the educational TalkingText.ahk script found below which voices the letters of the keyboard. then makes animal sounds when certain animal names are spelled (e.g. cat, dog, bear, and more).
• OverusedWords.zip contains OverusedWords.ahk and OverusedWords.exe
The OverusedWords script is a Hotstring app which pops up a menu of replacements for a list of overused words—as determined by English teachers when grading papers. While this script is primarily for students, anyone who wants to improve their writing may benefit. Chapter Eleven of Beginning AutoHotkey Hotstrings discusses this script.
• PathCheck.zip contains PathCheck.ahk and PathCheck.exe
The PathCheck script is merely a message box which displays the paths represented by the AutoHotkey variables A_UserName, A_MyDocuments, and A_AppData respectively.
• PhoneRing.zip included in Chapter Six of the AutoHotkey Applications e-book.
This is Ellen's script which combines a graphic file, an audio file, and the computer voice to display a multimedia message. The ZIP file includes, PhoneRing.ahk, PhoneRing.exe (which has the files Phone.jpg and Windows Ringin.wav embedded in the single compiled version). Activated with ALT+P, it is a demonstration of using a splash image with audio as a message, then compiling all the files into one executable package which not only runs on any Windows computer, but cleans up after itself.
PhoneRing.ahk is another example of AutoHotkey techniques which might enhance children's educational apps.
• PhraseOMatic.zip A Cool Little App for Inputting Common Phrases
PhraseOMatic is an AutoHotkey script which makes it easier to enter key phrases into any document or text editing field for work and personal use. No more memorizing hotstrings or hotkey combinations. This script is written by Douglas Abernathy which puts all of your important phrases into a pop-up menu. (Douglas can be reached at email@example.com if you have any questions about PhraseOMatic or unreasonable demands for new features.) Along with the PhraseOMatic.ahk and PhraseOMatic.exe files, there is a Readme.txt file and example phrase files found in PhraseOMatic.zip.
Download the original PhraseOMatic article "A Cool Little App for Inputting Common Phrases" in PDF format.
• Poetry Scripts (PoeticWords.ahk and RhymeMenu.ahk)
RhymeMenu.zip includes both the AHK file and an executable EXE file which runs without needing AutoHotkey installed.
These two scripts illustrate examples of how AutoHotkey might help poets in their quest for beautiful words (PoeticWords.ahk) and/or rhymes (RhymeMenu.ahk, shown at right). The Poetic Words script contains over 500 Hotstrings for replacing common words with more pretentious counterparts. The Rhyme Menu app downloads lists from www.rhymer.com, parses them with Regular Expressions, then inserts the selected option.
Introduced in the "Why AutoHotkey?" series found at Jack's AutoHotkey Blog, "Why AutoHotkey for Poets?" discusses these scripts
The QuickLinks script sets up a pop-up menu system with a special QuickLinks folder of your favorite shortcuts whether programs or Web pages. It may be a suitable replacement for the missing Start Menu in Windows 8, although I use it regularly in both Windows 7 and Windows Vista as a quick way to open working pages on the Web and a couple of programs. For the standard version of QuickLinks, once loaded, the menu is accessed with the hotkey combination WIN+Z. In a modified version, QuickLinksTray, the menu structure is added to the System Tray icon right-click menu. The QuickLinks.zip file now includes QuickLinks.ahk QuickLinks.exe, QuickLinksTray.ahk and QuickLinksTray.exe.
Explanations of the QuickLinks script are included in this special Web page and one part of the e-book Digging Deeper Into AutoHotkey.
• QuikPlay.zip contains QuikPlay.ahk and QuikPlay.exe included in the AutoHotkey Applications e-book.
The QuikPlay script is a barebones Windows media player. It operates with either hotkey combinations or selections from the right-click menu from the System Tray icon. Once QuikPlay is loaded these are the hotkey combinations and menu selections:
WIN+ALT+P => "Pick What to Play"
WIN+ALT+W => "What's Playing?"
WIN+ALT+N => "Next"
WIN+ALT+S => "Stop Play"
The QuikPlay.zip file was added for downloading convenience.
• QuickPrompt.zip included in the chapter on "Stealing AutoHotkey Scripts" in the e-book AutoHotkey Tricks You Ought To Do With Windows" in the "Quick Command Prompt" section.
This AutoHotkey script which I call QuickPromp adds the Command Prompt capability directly to the folder/file path field (address bar) in Windows Explorer. You no longer need to open the Command Prompt from the Start Menu or pin a quick launch to the Taskbar. Wherever you have Windows Explorer open, you can either run commands as if you were using the Command Prompt or open the window set to the current folder. The activating key is a slash (/).
I found the source code for QuickPromp.ahk at this AutoHotkey forum post. This one was written by Rajak and I did not make any modifications. I merely compiled it into QuickPrompt.exe for running on any windows computer. Both files can be extracted from QuickPrompt.zip after downloading from the ComputorEdge AutoHotkey download site.
• RecipeTree.zip contains a number of versions of RecipeTree.ahk which are included in the AutoHotkey Applications e-book.
A six-part series demonstrating an alternative application using the TreeView AutoHotkey GUI control.
This AutoHotkey script uses a fairly advanced technique for attaching TreeView branches to GUI Edit control data fields by saving variable names within variables.
• RegExTester.zip (RegExTester.ahk) by Robert Ryan. When I started working with Regular Expressions (RegEx) in AutoHotkey, I was writing tiny AutoHotkey scripts, testing each attempt, then making changes and testing again…and again. Eventually, I checked the AutoHotkey Scripts Forum and found this Regular Expression Tester written by Robert Ryan in AutoHotkey. It's pretty slick, saves a lot of time, and offers instant understanding into how any AutoHotkey RegExs work. This RegEx Tester is used extensively to explain AutoHotkey Regular Expressions in the e-book A Beginner's Guide to Using Regular Expressions in AutoHotkey. Plus, there are articles at Jack's AutoHotkey Blog highlighting the RegEx Tester.
• Reminder.zip contains a number of variations of Reminder.ahk and Reminder.exe
The Reminder script has gone through many iterations and has more to come—although I'm not sure when. I use it to tell me to take out the trash on the right day and other quick temporary reminders. It is called up with the hotkey combination CRTL+WIN+R plus the most recent version has a Set Reminder option in the System Tray icon right-click menu.
The various versions of the files (some compiled into EXE files) have been included for people who are reading the related articles. They are now combined in the Reminder.zip file. The following is a list of the articles in order in which they deal with the different versions of the Reminder script:
Explanations of the Appointment Reminder script are incorporated in more detail in one section of the e-book Digging Deeper Into AutoHotkey and extended in Chapters Thirty-two and Thirty-three in the e-book AutoHotkey Applications. I encourage anyone to tailor the script for personal use—possibly adding a multiple reminder capability and a repetitive reminder feature. I plan to do that myself when the time is right.
Various versions of the Reminder script can be downloaded in Reminder.zip at the ComputorEdge AutoHotkey download site.
• SaveText.ahk discussed in Part IV "Collect Data in One Pot" of the e-book Digging Deeper Into AutoHotkey.
The SaveText script copies selected text to a Notepad editing window. If it isn't already open, the script launches Notepad. The CTRL+ALT+S hotkey combination is used to copy the selected text from other programs or Web pages.
The newer CopyRef.ahk script offers a more faster, robust form of SaveText.ahk with more protections using the standard AutoHotkey Clipboard routine.
• SayWhat.zip contains SayWhat.ahk and SayWhat.exe included in the AutoHotkey Applications e-book.
This SayWhat script is a demonstration of how easy it is to use the text reading capability of Windows with AutoHotkey. Once the script is loaded a "Speak to Me!" window will open. Type in any text and click "Talk!" The default Windows voice reads the text out loud.
• ScreenDimmer.zip containing ScreenDimmer.ahk and ScreenDimmer.exe is included in Chapter Eight of the AutoHotkey Applications e-book.
Demonstrates the AutoHotkey Slider control in a GUI which dims the computer screen. The second section adds an AutoHotkey Statusbar control which can reset the screen control, plus a one-click pop-up in the System Tray.
• SeeThruWinWheel.ahk— The script contains three Hotkey combinations for adjusting the transparency level of any window: Control & WheelUp, Control & WheelDown, and Control & LButton. Each uses the mouse in combination with the CTRL key. Since it's natural to change levels continuously, it makes sense to use the scroll wheel rather than a regular Hotkey combination.
Plus, by using the MouseGetPos command, the target window no longer needs to be the active window. Merely hovering over the window allows AutoHotkey to grab the windows name:
That means you can peek under any window covering another spot on the screen by increasing the window transparency (decreasing opaqueness) without clicking on it.
• SmartGUI Creator — A tool for quick GUI window code creation.
SmartGUI.zip contains SmartGUI.exe, calc.ahk, and Manual.htm. The code generation utility for creating WYSIWYG Graphical User Interfaces (GUI) was written by Rajat, a prolicfic writer of excellent AutoHotkey scripts. It can be a tremendous time saver when designing the layout of your controls. For more information get the article "Writing AutoHotkey Code Fast with SmartGUI Creator."
• StateInsert.zip (StateInsert.ahk) The online AutoHotkey documentation for the Input command includes an excellent example of how it can be used for expanding abbreviations. Modifying that example creates temporary Hotstrings for inserting all 50 states plus the District of Columbia into any documents by typing the two-letter postal code. (Included in "Chapter Sixteen: Create Instant Temporary AutoHotkey Hotstrings with the Input Command" of the Beginning AutoHotkey Hotstrings e-book.)
• StripReturns.zip "A Short Script for Removing Embedded Misplaced New Line Characters" This fixes the problem when paragraphs don't wordwrap. (Included in "Chapter Twenty-eight: Fixing Broken Word Wraps" of the AutoHotkey Applications e-book.) (StripReturns.ahk and StripReturns.exe)
• SynonymLookup.zip This short beginning AutoHotkey strip demonstrates how to use the Windows Clipboard to quickly access reference sites on the Web. In this case, after hitting the Hotkey combination CTRL+ALT+L, Thesaurus.com opens in the default browser using the word highlighted in any text to find synonyms. (Referenced in the blog "Why AutoHotkey for Writers, Bloggers, and Editors?") The ZIP file includes both the AHK script and the compiled EXE file which runs on any Windows PC even without AutoHotkey installed. (SynonymLookup.ahk and SynonymLookup.exe)
• TalkingText.zip contains TalkingText.ahk, TalkingText.exe and the folders audio-alphabet (WAV files for each letter of the alphabet in a womans' voice) and Sounds (WAV files for sounds of eight different animals plus a train). The discussion of this script is currently only available in a ComputorEdge Archives PDF.
Hotstrings activate the WAV file for each corresponding letter key and speak the letters in a womans' voice. Spelling certain animal names invokes the sound of that animal after a space bar or period is pressed. This script offers alternative Hotstring approaches to the children's eductional script NumbersSpeak.ahk available above.
• ToDoList.zip contains ToDoList.ahk and ToDoList.exe included in Chapter Nine and Chapter Ten of the AutoHotkey Applications e-book.
This ToDoList.ahk script creates a one-column ListView window which displays text items in a list of tasks. This text list is saved to a text file (ToDoList.txt) in the same folder as the script. (That way, if you exit the app or your computer crashes, you will still have your complete "to-do list" available the next time you logon.) With a right-click on ListView, items can be edited or deleted. A closed To Do List window can be reopened with CTRL+ALT+T or with the right-click menu from the System Tray icon.
To add new items, enter the text into the editing field at the bottom of the window and click "Add to list:" on the left side at the bottom of the window. Select Edit from the right-click menu to put the item text into the editing field at the bottom. Click Update to save changes. Click the heading "Items To Do" to reverse the order of the items. Each item can be checked when completed or deleted with the right-click menu.
• ToDoList Color.zip Chapter Thirty-six "Adding Color to ListView Rows" of the AutoHotkey Applications e-book.
This script is a newer version of the ToDoList script (ToDoList Color.ahk) above. It demonstrates how to add color to the individual ListView rows, then turn each on and off with the CheckBox.
• ToolTipTest.zip and ToolTipTest2.zip contain ToolTipTest.ahk plus ToolTipTest.exe and ToolTipTest.ahk plus ToolTipTest.exe respectively. Included in the AutoHotkey Applications e-book.
Both the ToolTipTest and ToolTipTest2 scripts are demonstrations of how to use Windows Tooltips to provide information. ToolTipTest is an example of using the Tooltip within an AutoHotkey window. ToolTipTest2 provides AutoHotkey specific information on each window as the cursor hovers over it.
• WindowList.ahk for finding lost windows, included in Chapter Thirteen of the Digging Deeper Into AutoHotkey e-book.
The idea for the WindowList script was inspired by a reader wanting to bring lost (off-screen) windows back in view. This script makes a dropdown menu of all the open windows (CTRL+WIN+L to activate after load). The list is filtered to avoid Windows system windows. When a window is selected from the menu, it is activated and positioned on top near the upper left-hand corner of the screen.
• WindowMove.ahk included in the e-book Digging Deeper Into AutoHotkey.
The WindowMove script is a demonstration app similar to Aero Snap. When the hotkey combination CTRL+WIN+M is activated, the script creates a dropdown list of moving and sizing options for the last active window. It only moves that last window activated. To move another window the menu must be closed, the new windows selected, the CTRL+WIN+M.
I put together this quick tool I call WindowProbe.ahk for capturing some of the same AutoHotkey information displayed by Window Spy, but in a different format. WindowProbe uses a tooltip help pop-up to display vital information as you move the mouse cursor around the screen (as shown at right).
The hotkey combination CRL++T (^#T) toggles the tooltip message on and off. Since you may want to capture this information for use in an AutoHotkey script, the CTRL+F12 key combination saves the codes in the Windows Clipboard. After capturing in the Clipboard, it can be pasted into any text document or file in this format:
Unique ID: ahk_id 0x1b051c<(Download Index)
• WindowRollup.zip (WindowRollup.ahk) included in the chapter on "Stealing AutoHotkey Scripts" in the e-book AutoHotkey Tricks You Ought To Do With Windows.
The WindowRollup script is designed to semi-minimize active windows making it easier to see what's behind them and quickly access running programs on the Windows Desktop. The difference with this WindowRollup app from the previous HideWindow script is that rather than hiding or minimizing an open window, it reduces the window size to the title bar (or close to it)—making it possible to keep a good number of active windows on the Desktop without them interfering with each other.
The app works as a toggle using the CTRL+Z hotkey combination. (I changed the hotkey from the original +Z because I was using +Z for my QuickLinks menu app. I discuss how to make this change in the hotkeys in the chapter "A Beginner's Guide to Stealing AutoHotkey Apps." I note that you may not want to use CTRL+Z for the hotkey combination, since it is also the Undo hotkey in many programs. This app will block other CTRL+Z functions. It's easy to change the hotkey to something else by following the same steps in the e-book. The app called "Window Shading" was written by Rajak and the source is available through the AutoHotkey Scripts Showcase site.
• WinToolTipToggle.zip contains WinToolTipToggle.ahk and WinToolTipToggle.exe included in the AutoHotkey Applications e-book.
The WinToolTipToggle script is a demonstration of AutoHotkey changing a Windows Registry entry. In this case, the script toggles Windows Tooltips, the little labels that appear when you hover the mouse over a filename or icon. The option appears in a message window when the script is loaded.
More AutoHotkey Script Snippets
The scripts posted on the the ComputorEdge AutoHotkey download site are not all of the snippets I've published. Many only appear in the the e-books. For an extensive review of the more involved AutoHotkey scripts shown here see the e-book, AutoHotkey Applications.
* * *Get this AutoHotkey overview e-book, AutoHotkey Tricks You Ought to Do with Windows!
* * *The third edition with more chapters, tips and an index to the AutoHotkey commands found in the book is available in e-book format from Amazon (and other formats—EPUB and PDF— at the ComputorEdgeBooks Web site linked below). Jack's A Beginner's Guide to AutoHotkey, Absolutely the Best Free Windows Utility Software Ever!: Create Power Tools for Windows XP, Windows Vista, Windows 7 and Windows 8 (preferred, EPUB format for iPad, Android, and computers; MOBI for Amazon Kindle; and PDF for printing) offers a gentle approach to learning AutoHotkey. (Also available from Amazon for the Kindle and Kindle software on other devices.)
Building Power Tools for Windows XP, Windows Vista, Windows 7 and Windows 8, AutoHotkey is the most powerful, flexible, free Windows utility software available. Anyone can instantly add more of the functions that they want in all of their Windows programs, whether installed on their computer or while working on the Web. AutoHotkey has a universality not found in any other Windows utility—free or paid.
Originally based upon the series of articles in ComputorEdge, Jack takes you through his learning experience as he explores writing simple AutoHotkey scripts for adding repetitive text in any program or on the Web, running programs with special hotkeys or gadgets, manipulating the size and screen location of windows, making any window always-on-top, copying and moving files, and much more. Each chapter builds on the previous chapters.
For an EPUB (iPad, NOOK, etc.) version of A Beginner's Guide to AutoHotkey click here!
For a PDF version for printing on letter size paper for inclusion in a standard notebook of A Beginner's Guide to AutoHotkey click here!
(Get the Spanish language version of A Beginner’s Guide to AutoHotkey—Guía Básica de AutoHotkey—from Amazon.)
* * *
Jack's second AutoHotkey book, Digging Deeper Into AutoHotkey (preferred, EPUB format for iPad, Android, and computers; MOBI for Amazon Kindle; and PDF for printing) is comprised of updated, reorganized and indexed columns from ComputorEdge is now available. Since the columns were not all written in a linear fashion, the book has been reorganized and broken up into parts by topic. The book is not for the complete beginner since it builds on the information in A Beginner's Guide to AutoHotkey. However, if a person is reasonably computer literate, they could go directly to this book for ideas and techniques without the first book. (Also available from Amazon for the Kindle and Kindle software on other devices.)
For an EPUB (iPad, NOOK, etc.) version of Digging Deeper into AutoHotkey click here!
For a PDF version for printing on letter size paper for inclusion in a standard notebook of Digging Deeper into AutoHotkey click here!
* * *
Jack's third AutoHotkey book AutoHotkey Applications (preferred, EPUB format for iPad, Android, and computers; MOBI for Amazon Kindle; and PDF for printing) is an intermediate level book of ideas and applications based primarily on the AutoHotkey GUI command. The book emphasizes practical applications. The book is not for the complete beginner since it builds on the information in the other two books. However, if a person is reasonably computer literate, they could go directly to this book for ideas and techniques without the other books. There is an extensive index to the ideas and techniques covered in the back of the book. (Also available from Amazon for the Kindle and Kindle software on other devices.)
For an EPUB (iPad, NOOK, etc.) version of AutoHotkey Applications click here!
For a PDF version for printing on letter size paper for inclusion in a standard notebook of AutoHotkey Applications click here!
* * *
As a convenience for people who don’t want to dig through the Web for individual tips, but would like to learn some cool AutoHotkey Hotstring tricks, the e-book Beginning AutoHotkey Hotstrings is now available on the ComputorEdge E-Books site and through Amazon. If e-books are not your thing, then it might be worth your time to peruse some of the blogs included in this book and linked at “Beginning AutoHotkey Hotstring Techniques” found under the “AutoHotkey Topics and Series” tab in the top menu bar. They just might inspire your next AutoHotkey script.Beginning Hotstrings explores the potential of the basic AutoHotkey Hotstring option and how they can aid anyone who uses word processors, text editors, or Web input fields on Windows computers. It's surprising how this one small area of AutoHotkey can add power to your computer through Hotstring menus and the enigmatic Input commmand.
* * *
This Beginner's Guide to Using Regular Expressions in AutoHotkey is not a beginning level AutoHotkey book, but an introduction to using Regular Expressions in AutoHotkey (or most other programming languages). To get the most from this book you should already have a basic understanding of AutoHotkey (or another programming language). Regular Expressions (RegEx) are a powerful way to search and alter documents without the limitations of most of the standard matching functions. At first, the use of RegEx can be confusing and mysterious. This book clears up the confusion with easy analogies for understanding how RegEx works and examples of practical AutoHotkey applications. "Regular Expressions in AutoHotkey" will take you to the next level in AutoHotkey scripting while adding more flexibility and power to your Windows apps. (This book is also available at Amazon.com)