AutoHotkey Tricks

You Ought To Do With Windows

By Jack Dunning

© ComputorEdge E-Books, 2017

Table of Contents

AutoHotkey Tricks You Ought To Do With Windows

Fair Use Copyright

Introduction to AutoHotkey Tricks You Ought to Do

The Things You Ought To Do

Installing AutoHotkey

Writing Your First AutoHotkey Script

The Power of AutoHotkey

Reference Look Up For AutoHotkey Books

Chapter One: Add Tailored Signatures to All E-mail and Documents

Adding Your Signature to Anything

How It Works

Adding Blocks of Text

Chapter Two: Use AutoHotkey to Instantly Insert Your E-Mail Address into Web Forms

Hotstrings for Entering E-mail Addresses

Adding a Password

Logging in with Different Web Pages

Chapter Three: Use AutoHotkey to Instantly Turn Hard-to-Type Jargon into Hotstrings

Chapter Four: Adding Currencies, Special Symbols and Fractions, Plus Today's Date

Automatically Adding the Special Characters to Documents and Editing Fields

Tip for Adding Today's Date to Any Document

Chapter Five: Web Site Searches Made Easy

Setting Up Your Own Favorite Web Site Search

Making a Pop-up Search Window

The AutoHotkey GUI (Graphic User Interface)

The vVariable Option

The gLabel Option

The Hotkey Combination and Gui, Show

Adding an Item to the AutoHotkey System Tray Right-click Menu

Eliminating the Hotkey Combination

Chapter Six: Hotkeys to Automate Right-click Menus

Preventing Action from a Wandering Mouse

A Simpler, More Effective Technique

The Windows Context Menu

Limit the Hotkey to the Proper Program

Finding Window Titles and Control Names with WindowProbe

Toggling On and Off

Chapter Seven: Quickly Open Favorite Folders

Open Folders Instantly

Open Folders with a Pop-up Menu

Adding Hotkeys to the Menu

Adding the Menu to the System Tray Right-Click Menu

Shortening the Menu

Chapter Eight: Using Extra Mouse Buttons and the Wasted Insert Key

Make Use of Extra Buttons on Your Mouse with AutoHotkey

Making Better Use of the Insert and CapsLock Keys

Chapter Nine: A Beginner's Guide to Stealing AutoHotkey Apps, Plus Writing and Running Scripts

Install AutoHotkey

Stealing an AutoHotkey Script

Run Stolen AutoHotkey Apps at Startup

Simple Script Tailoring for Personal Use

Finding and Changing the Hotkey

Adding Scripts to Other Scripts

More Auto-Execute

Four AutoHotkey Apps Worth Stealing

Google Spelling and Grammar AutoCorrect

Hide a Window So No One Knows It Exists

Rollup Windows for More Breathing Space

Quick Command Prompt

Anyone Can Use These Apps

Chapter Ten: AutoHotkey Versus AutoIt

The Names AutoHotkey and AutoIt

AutoHotkey Versus AutoIt for Hotkeys and Hotstrings

The Confusing Side of AutoHotkey

Interest in AutoHotkey Versus AutoIt

"A Beginner's Guide to AutoHotkey" Contents and Index

Table of Contents to "A Beginner's Guide"

Index to "A Beginner's Guide"

A—Index to "A Beginner's Guide"

B—Index to "A Beginner's Guide"

C—Index to "A Beginner's Guide"

D—Index to "A Beginner's Guide"

E—Index to "A Beginner's Guide"

F—Index to "A Beginner's Guide"

G—Index to "A Beginner's Guide"

H—Index to "A Beginner's Guide"

I—Index to "A Beginner's Guide"

K—Index to "A Beginner's Guide"

L—Index to "A Beginner's Guide"

M—Index to "A Beginner's Guide"

N—Index to "A Beginner's Guide"

O—Index to "A Beginner's Guide"

P—Index to "A Beginner's Guide"

R—Index to "A Beginner's Guide"

S—Index to "A Beginner's Guide"

T—Index to "A Beginner's Guide"

U—Index to "A Beginner's Guide"

V—Index to "A Beginner's Guide"

W—Index to "A Beginner's Guide"

X—Index to "A Beginner's Guide"

"Digging Deeper into AutoHotkey" Contents and Index

The Table of Contents "Digging Deeper into AutoHotkey"

Index to the E-Book "Digging Deeper into AutoHotkey"

A—Index to "Digging Deeper"

B—Index to "Digging Deeper"

C—Index to "Digging Deeper"

D—Index to "Digging Deeper"

E—Index to "Digging Deeper"

F—Index to "Digging Deeper"

G—Index to "Digging Deeper"

H—Index to "Digging Deeper"

I—Index to "Digging Deeper"

K—Index to "Digging Deeper"

L—Index to "Digging Deeper"

M—Index to "Digging Deeper"

N—Index to "Digging Deeper"

O—Index to "Digging Deeper"

P—Index to "Digging Deeper"

Q—Index to "Digging Deeper"

R—Index to "Digging Deeper"

S—Index to "Digging Deeper"

T—Index to "Digging Deeper"

U—Index to "Digging Deeper"

V—Index to "Digging Deeper"

W—Index to "Digging Deeper"

"AutoHotkey Applications" Contents and Index

The Table of Contents "AutoHotkey Applications"

Index to "AutoHotkey Applications"

A—Index to "AutoHotkey Applications"

B—Index to "AutoHotkey Applications"

C—Index to "AutoHotkey Applications"

D—Index to "AutoHotkey Applications"

E—Index to "AutoHotkey Applications"

F—Index to "AutoHotkey Applications"

G—Index to "AutoHotkey Applications"

H—Index to "AutoHotkey Applications"

I—Index to "AutoHotkey Applications"

J—Index to "AutoHotkey Applications"

L—Index to "AutoHotkey Applications"

M—Index to "AutoHotkey Applications"

N—Index to "AutoHotkey Applications"

O—Index to "AutoHotkey Applications"

P—Index to "AutoHotkey Applications"

Q—Index to "AutoHotkey Applications"

R—Index to "AutoHotkey Applications"

S—Index to "AutoHotkey Applications"

T—Index to "AutoHotkey Applications"

U—Index to "AutoHotkey Applications"

V—Index to "AutoHotkey Applications"

W—Index to "AutoHotkey Applications"

X—Index to "AutoHotkey Applications"

Y—Index to "AutoHotkey Applications"

"A Beginner's Guide to Using Regular Expressions in AutoHotkey" Contents and Index

Table of Contents to "A Beginner's Guide to Using Regular Expressions in AutoHotkey"

Index to "A Beginner's Guide to Using Regular Expressions in AutoHotkey"

Regular Expressions (RegEx) A-C

Regular Expressions (RegEx) D-F

Regular Expressions (RegEx) G-L

Regular Expressions (RegEx) M-O

Regular Expressions (RegEx) P-R

Regular Expressions (RegEx) S-T

Regular Expressions (RegEx) U-W

"Beginning AutoHotkey Hotstrings" Contents and Index

A Practical Guide for Creative Autocorrection, Text Expansion, and Text Replacement

Table of Contents

Index to Beginning AutoHotkey Hotstrings

#

*

?

`

{

A — Beginning AutoHotkey Hotstrings Index

B — Beginning AutoHotkey Hotstrings Index

C — Beginning AutoHotkey Hotstrings Index

D — Beginning AutoHotkey Hotstrings Index

E — Beginning AutoHotkey Hotstrings Index

F — Beginning AutoHotkey Hotstrings Index

G — Beginning AutoHotkey Hotstrings Index

H — Beginning AutoHotkey Hotstrings Index

I — Beginning AutoHotkey Hotstrings Index

K — Beginning AutoHotkey Hotstrings Index

L — Beginning AutoHotkey Hotstrings Index

M — Beginning AutoHotkey Hotstrings Index

O — Beginning AutoHotkey Hotstrings Index

P — Beginning AutoHotkey Hotstrings Index

R — Beginning AutoHotkey Hotstrings Index

S — Beginning AutoHotkey Hotstrings Index

T — Beginning AutoHotkey Hotstrings Index

U — Beginning AutoHotkey Hotstrings Index

V — Beginning AutoHotkey Hotstrings Index

W — Beginning AutoHotkey Hotstrings Index

AutoHotkey Hotkeys: Tips, Tricks, Techniques, and Best Practices for Automating Your Windows Computers with Hotkey Combinations—Something for Everyone!

Table of Contents AutoHotkey Hotkeys

Index to AutoHotkey Hotkeys

! Hotkey Book

%

&

^

~

+

<

>

A Hotkey Book

B Hotkey Book

C Hotkey Book

D Hotkey Book

E Hotkey Book

F Hotkey Book

G Hotkey Book

H Hotkey Book

I Hotkey Book

K Hotkey Book

L Hotkey Book

M Hotkey Book

N Hotkey Book

O Hotkey Book

P Hotkey Book

Q Hotkey Book

R Hotkey Book

S Hotkey Book

T Hotkey Book

V Hotkey Book

W Hotkey Book

X Hotkey Book

Beginning Tips for Writing AutoHotkey Scripts

Beginning Tips for Writing AutoHotkey Scripts—Table of Contents

Foreword—Beginning Tips for Writing AutoHotkey Scripts

Chapter One: How AutoHotkey Reads Scripts—Beginning Tips for Writing AutoHotkey Scripts

Chapter Two: Modular Independence of Hotstrings—Beginning Tips for Writing AutoHotkey Scripts

Chapter Three: Modular Independence of HotKeys—Beginning Tips for Writing AutoHotkey Scripts

Chapter Four: Functions as Building Blocks—Beginning Tips for Writing AutoHotkey Scripts

Chapter Five: Enclosed Label Subroutine Building Blocks—Beginning Tips for Writing AutoHotkey Scripts

Chapter Six: Methods for Running Label Subroutines—Beginning Tips for Writing AutoHotkey Scripts

Chapter Seven: Understanding Label Names and Subroutines—Beginning Tips for Writing AutoHotkey Scripts

Chapter Eight: GoTo Command Versus GoSub Command—Beginning Tips for Writing AutoHotkey Scripts

Chapter Nine: Reset Hotkeys with Label Name Drop-Through Behavior—Beginning Tips for Writing AutoHotkey Scripts

Chapter Ten: Techniques for Merging Standalone AutoHotkey Scripts—Beginning Tips for Writing AutoHotkey Scripts

Chapter Eleven: How to Write Easy-Merge AutoHotkey Scripts—Beginning Tips for Writing AutoHotkey Scripts

Chapter Twelve: Writing AutoHotkey Functions to Make Life Easier—Beginning Tips for Writing AutoHotkey Scripts

Chapter Thirteen: AutoHotkey Commands Versus #Directives—Beginning Tips for Writing AutoHotkey Scripts

Index to Beginning Tips for Writing AutoHotkey Scripts

#—Beginning Tips for Writing AutoHotkey Scripts

%—Beginning Tips for Writing AutoHotkey Scripts

^—Beginning Tips for Writing AutoHotkey Scripts

A—Beginning Tips for Writing AutoHotkey Scripts

B—Beginning Tips for Writing AutoHotkey Scripts

C—Beginning Tips for Writing AutoHotkey Scripts

D—Beginning Tips for Writing AutoHotkey Scripts

E—Beginning Tips for Writing AutoHotkey Scripts

F—Beginning Tips for Writing AutoHotkey Scripts

G—Beginning Tips for Writing AutoHotkey Scripts

H—Beginning Tips for Writing AutoHotkey Scripts

I—Beginning Tips for Writing AutoHotkey Scripts

L—Beginning Tips for Writing AutoHotkey Scripts

M—Beginning Tips for Writing AutoHotkey Scripts

N—Beginning Tips for Writing AutoHotkey Scripts

O—Beginning Tips for Writing AutoHotkey Scripts

P—Beginning Tips for Writing AutoHotkey Scripts

Q—Beginning Tips for Writing AutoHotkey Scripts

R—Beginning Tips for Writing AutoHotkey Scripts

S—Beginning Tips for Writing AutoHotkey Scripts

T—Beginning Tips for Writing AutoHotkey Scripts

U—Beginning Tips for Writing AutoHotkey Scripts

V—Beginning Tips for Writing AutoHotkey Scripts

W—Beginning Tips for Writing AutoHotkey Scripts

Library Members! How to Get Your Discount!

Table of Contents Beginning Hotstrings Index

Jack's Motley Assortment of AutoHotkey Tips

How to Get Your ComputorEdge AutoHotkey Library Discount forJack's Motley Assortment of AutoHotkey Tips

Miscellaneous AutoHotkey Tips

Table of Contents — Jack's Motley Assortment of AutoHotkey Tips

1.1 Date Tricks Section

A Trick for Inserting Next Friday's Date

An AutoHotkey Technique for Determining Date for a Coming Day of the Week

Turning a Simple Weekday Date Trick into an Easy AutoHotkey Function

If You Need to Do It Over and Over Again, Make It an AutoHotkey Function

2.1 Clipboard Tricks Section

Peek Inside Windows Clipboard, Part 1 (Beginning AutoHotkey Tip)  A Quick, Easy Way to View Windows Clipboard Contents

Peek Inside Windows Clipboard, Part 2 (Intermediate AutoHotkey OnClipboardChange Tip) An AutoHotkey OnClipboardChange Script for Running the Most Appropriate of Two Different Clipboard Peeking Apps

3.1 Mouse Tricks Section

Changing Mouse Cursor Speed with AutoHotkey API Calls Slowing Down Mouse Cursor Movement with DllCall()

A Look at the AutoHotkey DllCall() Function

Window Mouse Transparency Wheel Handy Window Transparency Wheel Using Macro Replacement Quickly Peeks Under a Window without Moving It, Plus the Difference Between % Var and %Var% Made Easy Mouse Transparency Wheel: Reset Hotkeys with Label Name Drop-Through Behavior Sometimes Not Encapsulating Hotkeys with the Return Command Serves a Purpose Blocking Mouse Action Clarification of Other AutoHotkey BlockInput Command Tips

4.1 AutoHotkey Menus Section

Windows System Tray Icon Context Menu

Dynamically Switch the Actions of a Running AutoHotkey Script with a Simple Click of a System Tray Right-Click Menu Item

Stuffing More into AutoHotkey Pop-up Menus Rather Than Increasing the Length of a System Tray Menu, Add Submenus—Plus, How to Use Menu Names (A_ThisMenu) for Conditional Actions, Plus Printing from the System Tray Menu

Eliminate Hotkeys with AutoHotkey Menus

Why Memorize a Bunch of Hotkey Combinations When Using an AutoHotkey Pop-up Menu Does the Trick?

Automatically Add Windows Shortcuts to the QuickLinks App Rather than Manually Creating Windows Shortcuts for QuickLinks.ahk, Use the AutoHotkey FileCreateShortcut Command

Spice Up AutoHotkey Menus with Icons Using the Right Images Make Your AutoHotkey Menus Both Prettier and More Useful

Finding Windows Icons for AutoHotkey Menus

A Useful AutoHotkey Script for Quickly Identifying Icons Embedded in Other Windows Files

Add Secret Windows Tools (God Mode) to QuickLinks Menu This Windows Trick Works in Vista, Windows 7, 8, and 10

Using Unique Icons for Specific Windows Shortcuts Draw Icons for AutoHotkey Menus Directly from Windows Shortcuts

5.1 Window Manipulation with the WinSet Command

Make a Window Transparent Using the WinSet Command (Beginning AutoHotkey Tip)

After Setting a Window to Always-On-Top, Make It See-through for Peeking Underneath

The WinSet, ExStyle Command for Mouse Click-Thru Transparent Windows (Intermediate AutoHotkey Tip)

After Always-On-Top and Translucent Windows, Use the WinSet Command to Make a Mouse-Click Transparent Help Window, Plus a Discussion of the Mysterious (and Confusing) Microsoft Window Styles/ExStyles (WS_XXX and WS_EX_XXX)

WinSet, TransColor Command for Both Transparent and Mouse Click-Thru Windows (Intermediate AutoHotkey Tip)

The WinSet, TransColor Option Offers an Alternative Method for Placing Data and/or Images Onscreen and On Top without Interfering with Your Work

Change Window Shapes Using the WinSet, Region Command (Intermediate AutoHotkey Tip)

Make Odd Shaped Windows with the AutoHotkey WinSet, Region Command, Plus a Script for Creating a Mouse Spotlight Examine Window Status with WinGet, ExStyle ExStyle Settings Help to Polish AutoHotkey Window Manipulation Scripts, Plus a Couple More Tricks

6.1 Education Section

Entertaining and Educating Toddlers with a Talking Keyboard

Toddlers Turn Your Windows Keyboard into a Learning Experience--Teaching the Alphabet with Animal Sounds

More AutoHotkey Entertainment and Education Scripts with Tools for Creating Educational Scripts

7.1 AutoHotkey Web Search Section

Make Simple Instant Web Page Searches Your Online Thesaurus

Expand Your Vocabulary with This Quick and Dirty AutoHotkey Tip Or Modify This Script for Any Web Page Search

Learn a Hidden AutoHotkey Trick for Quickly Accessing AutoHotkey Online Command Information

The Problem with Accessing Web Data with AutoHotkey Scripts

The Trouble with Scripts Which Use Web Page Information, Plus AutoHotkey Tools for Downloading Web Page Source Code

AutoHotkey Quick Reference Script

The AutoHotkey.com built-in Index Reappears—Now to Build a Reference Tool!

Regular Expressions (RegEx) for Parsing Text (AutoHotkey Quick Reference Script)

The RegExReplace() Function Makes It Easy to Extract and Cleanup Text, Plus a Quick-and-Dirty RegEx to Strip All HTML Tags

Using INI Files for Web Address (URL) Letter Case-Sensitivity Problems (AutoHotkey Quick Reference Script)

The Wrong Capitalization of Letters in URLs Can Cause Page Access Failure—A Trick for Using an INI File to Solve Case Problems in AutoHotkey Ryan’s RegEx Tester for Building INI Data Files(AutoHotkey Quick Reference Script)

Sometimes It’s Quicker and Easier to Use Ryan RegEx Tester Rather Than Writing an AutoHotkey Script

Too Much Planning Can Get in the Way of Good Scripting (AutoHotkey Quick Reference)

While Preplanning Script Writing Can Be Useful, Don’t Take It Too Seriously—Sometimes It Only Makes Sense to Rewrite Everything

8.1 Windows Automation Section

Control Windows Programs with AutoHotkey (Windows Paint Automation, Part One) AutoHotkey Uses Windows Paint to Demonstrate How to Draw and Fill In a Square with AutoHotkey Use AutoHotkey to Draw a Straight Line (Windows Paint Automation, Part Two) While You May Never Need to Do This, this AutoHotkey Techniques Apply to Many Other Applications Make Your Own Drawing Tools with AutoHotkey (Windows Paint Automation, Part Three) Build Functions With AutoHotkey to Create Controls for Windows Paint (or Any Other Program) Controlling More Tools with AutoHotkey (Windows Paint Automation, Part Four) Taking Another Step Toward Building Autohotkey Tools For Controlling Windows Programs Automatically Locate Buttons in Windows Programs by Color This Little Known Autohotkey Command Can Scan a Section of a Window or Image for a Specific Color. Use It to Select Colors In Windows Paint More Windows Program Automation with the WinMenuSelectItem Command…Maybe Traditional Style Windows Programs May Benefit by Automating with the WinMenuSelectItem Command

9.1 Using Regular Expressions (RegEx)

A Perfect Place to Use an AutoHotkey Regular Expression (RegEx in Text Replacement) Occasionally, You Run into a Search-and-Replace Problem that Cries Out for an AutoHotkey RegEx (Regular Expression). But, Is Learning How to Use Regular Expressions Worth Your Time? You Decide! Here’s a Real Problem and a Beginner’s Mini-Tutorial for Solving It with RegEx Regular Expressions (RegEx) don't immediately make sense to anyone—especially if you've never used them before. Even if you understand how they work, you may not find it easy to know where to apply them. This chapter offers one search-and-replace situation where a RegEx makes a huge difference and a short description of how the RegEx works. This chapter includes what you might consider a mini introduction to Regular Expressions. RegExReplace () function Deleting Duplicate Words with AutoHotkey Regular Expressions (RegEx) When Too Many Identical Chapter Numbers Appear in the E-Book Index, It’s Time for Another AutoHotkey RegEx, Plus, How to Use a Backreference! Quick and Dirty Complex Text Replacement with Ryan’s RegEx Tester While Not For Beginning AutoHotkey Script Writers, This Regular Expression (RegEx) Trick Executes Multiple Complex Text Replacements without Even Writing an AutoHotkey Script

10.1 AutoHotkey Printing Section

11.1 GUI Control and Data File Section

Calorie Counting with AutoHotkey Revisited The Calorie Counting Script Comes Out of the Drawer for New Features Creating the Food History List Using the Daily Food Count File We Construct a Sorted Food List for Future Reference Packing More Info into Apps with GUI Tabs The AutoHotkey Tab GUI Control Offers a Powerful Space Saver for Windows Apps When you find that you are adding so many data and editing fields to your AutoHotkey GUI windows that they turn into large, grotesque forms, then discover the Tab GUI control. Tabs instantly add more space to your apps without needing more screen. Resizing GUI Windows and Controls with the Calorie Counting Script, Plus Filtering Out Duplicate and Blank ListView Entries See How to Add One GUI Control to All Tabs, Make GUI Controls Resizeable, and Load the Food List ListView Control While Filtering Data Entries in the CalorieCount.ahk Script Using the GuiContextMenu Subroutine When Counting Calories After Adding a Second Tab with a Food List, It's Time to Add a New Right-Click Menu

12.1 Instant Hotkey GUI and Menu Section

AutoHotkey Solutions for Windows Clipboard Limitations (Temporary Hotkeys) Sometimes It’s Just Easier To Set Up a Temporary Hotkey for Inserting Text into Documents, Web Pages, or Forms, Plus a Quick Reminder of a Couple of Cool Clipboard-like AutoHotkey Apps (ClipJump and PhraseOMatic) Create Multiple InstantHotkey GUI Pop-Ups On-the-Fly in a Single Script This AutoHotkey GUI (Graphical User Interface) Trick Builds New GUIs (Graphical User Interfaces) On-the-Fly Simultaneously in the Same Script without Conflicts Two-Deep Variables for Tracking Data When You Find No Obvious Way to Link Specific Data to an Object or Another Value, You Might Try Saving It to a Variable within a Variable Matching Instant Hotkey Combinations with a Loop Sometimes You’ll Find a Loop a Simpler Way to Match Things Using Associative Arrays to Solve the Instant Hotkey Data Recall Problem While Many Other Approaches Work (Sort of), AutoHotkey Associative Arrays Provides a Simple Solution The AutoHotkey “For Key [, Value] in Expression” Loop for Associative Arrays The Standard AutoHotkey Loop Command Works Great for Incremental Series, But the For Key [, Value] in Expression Object Loop Offers Unique Flexibility for Associative Arrays Turn AutoHotkey System Tray Icons into One-Click Action Buttons Rather Than Using Hotkey Combinations, a Simple Click of the Icon in the Windows System Tray Launches Your App

13.1 Miscellaneous AutoHotkey Tips Section

Disabling Select Hotstrings to Prevent Replacement Misfires Every So Often You Slap Yourself on the Side of the Head When You Realized How Simple You Can Make It! Access Your Hotkeys with Hotstrings An AutoHotkey Hotstring Secret Using the Raw Option in Send Commands and Hotstrings Both Hotkey Modifiers and Special Characters Might Disappear When Used in Regular Text. Usually, You’ll Find the Raw Mode the Easiest Solution for Vanishing Characters. A Simple One-Line Pop-up Help Window One Line of Code Builds a Help Window Optimizing the AutoHotkey Message Box Use These AutoHotkey MsgBox Tricks for Adding Power and Flexibility to Your Scripts. If You Want a Simple, Quick Way to Display Data and Execute Action, You’ll Love These Techniques! Automatically Launch Apps at Windows Startup Discover Autohotkey Tricks By Perusing Code In Other Scripts, Plus How to Load Any Windows Program at Startup Control, EditPaste for Speed The Control, EditPaste Command Adds Great Speed to Standard Text Insertion Routines—within Certain Limits

14.1 AutoHotkey Apps Section

Free AutoHotkey Virtual Numeric Keypad App A Quick Little AutoHotkey App for Small Laptops with No Numeric KeyPad, Plus Always-on-top and Use without Making It Active EitherMouse for Lefties, the Ambidextrous, and Multiple Monitors A Clever Little Tool for Using Multiple Mice on the Same Computer, Plus a Peek at Some Advanced AutoHotkey Techniques Unhide Hidden Files with Windows Registry Setting to Find Lost Data Toggle Hidden Files, System Files, and File Extensions in the Windows Registry with this AutoHotkey Script A Quick, Light AutoHotkey Script for Background Music TinyShuffle, a Free App to Randomly Play Your Favorite Music A Quick and Dirty Windows Stopwatch Your Minute Is Up! Fix Grammar Problems with Google Search and GooglePhraseFix (Intermediate AutoHotkey Tip) The GooglePhraseFix AutoHotkey Script Corrects Many Common Spelling and Grammar Errors While Demonstrating How to Download Information from the Web…without Opening a Browser The Free AutoHotkey TypingAid App Adds Word Choice to All Windows Programs Add Word Recommendation Pop-ups to Your Programs An AutoHotkey Speed Reading App Who Doesn't Want to Read Faster?

15.1 AutoHotkey Tools Section

A Gadget to Check CPU Power Usage (Dynamic AutoHotkey Charts) Real-Time CPU Power Graph and AutoHotkey Chart Tools The Main Window for Debugging AutoHotkey Scripts How to View the Inner Workings and Hidden Mechanisms of Running AutoHotkey Scripts Writing AutoHotkey Code Fast with SmartGUI Creator (Part 1) A Powertool for Fast Design and Code Writing for Pop-up Windows The Easy Way to Build AutoHotkey GUI Windows (SmartGUI Creator, Part 2) How to Steal GUI Code from Any AutoHotkey Window, Plus More SmartGUI Creator Features

16.1 Special Tips and Errors

Possible Solution for Failing Hotkeys An Important Tip for Any AutoHotkey User Don't Overlook the ErrorLevel Variable When Writing AutoHotkey Scripts Make Your AutoHotkey Scripts More Robust by Using ErrorLevel Counting Commas with AutoHotkey A Quick AutoHotkey Tip for Counting Occurrences of Characters in a Text String

Index to Jack's Motley Assortment of AutoHotkey Tips

! — Motley AutoHotkey Tips

" — Motley AutoHotkey Tips

# — Motley AutoHotkey Tips

% — Motley AutoHotkey Tips

& — Motley AutoHotkey Tips

? — Motley AutoHotkey Tips

\ — Motley AutoHotkey Tips

^ — Motley AutoHotkey Tips

` — Motley AutoHotkey Tips

{ — Motley AutoHotkey Tips

+ — Motley AutoHotkey Tips

A — Motley AutoHotkey Tips

B — Motley AutoHotkey Tips

C — Motley AutoHotkey Tips

D — Motley AutoHotkey Tips

E— Motley AutoHotkey Tips

F— Motley AutoHotkey Tips

G — Motley AutoHotkey Tips

H — Motley AutoHotkey Tips

I — Motley AutoHotkey Tips

K — Motley AutoHotkey Tips

L — Motley AutoHotkey Tips

M — Motley AutoHotkey Tips

N — Motley AutoHotkey Tips

O — Motley AutoHotkey Tips

P — Motley AutoHotkey Tips

Q — Motley AutoHotkey Tips

R — Motley AutoHotkey Tips

S — Motley AutoHotkey Tips

T — Motley AutoHotkey Tips

U — Motley AutoHotkey Tips

V — Motley AutoHotkey Tips

W — Motley AutoHotkey Tips

X — Motley AutoHotkey Tips

Z — Motley AutoHotkey Tips

About the Author

Jack Dunning

Fair Use Copyright

“You should be able to read your e-books when you want and where you want.”

We believe that you should be able to peruse our e-books on any reading device you own. Therefore, we don't encrypt our books or implement Digital Rights Management. We depend upon your sense of fairness to determine how, when and where you will read our e-books.

Fair Use Copyright licenses the buyer to load this book on any device owned by the buyer. However, if you give it to someone else, you are in technical violation of the license for this e-book. (Well…not this book since it is offered free.) We don't know how we would know, so maybe you could go ahead and share this with a friend. With any luck at all, they will appreciate our years of work and purchase their own copy of the book, which is probably exactly like the one they already have (or just send us money for their current copy). Since this is an e-book there is always a chance that a newer copy will have new material. If you plan to give the e-book as a gift, purchase the download at our Web site, www.ComputorEdgeBooks.com.

If you've found this e-book useful and would like to kick in to the cause, you can send your contribution to ComputorEdge E-Books either through PayPal or credit card. Buying this book is contributing to a good cause—us!

This particular book, AutoHotkey Tricks You Ought To Do With Windows, is free and may be distributed freely. However, you may not copy any portion of this book and call it your own. Who must give credit by referencing this book and the author. While this book is free, if you're wondering about the price of another book, you can check with the normal distribution networks or at www.ComputorEdgeBooks.com.

All rights are reserved, so if you think that you're going to make this e-book into a movie, sell it on your own, or turn it into a t-shirt, we most likely will catch you when we view the previews on television or one of our devotees sees you at the beach wearing the shirt. It will then be worth it to send our army of attorneys after you—or whoever produced the t-shirt. It is probably best to contact us in advance so we can be friends.

© Copyright, ComputorEdge E-Books, 2017

Introduction to AutoHotkey Tricks You Ought to Do

“This free book offers some very useful (mostly beginning level) ideas for AutoHotkey while providing complete indexes to Jack's other books.”

Here are a number of simple AutoHotkey techniques that anyone can use to improve their Windows experience. Plus, if you're looking for more AutoHotkey information, the Table of Contents and Indexes for Jack's other AutoHotkey books are included in this free book.

After a number of years of using AutoHotkey (and writing seven other AutoHotkey books), I'm still convinced that it is absolutely the best free Windows utility software ever! One of my goals is to spread the word about AutoHotkey and show how easy it is for anyone to get started. That's why I regularly write a blog about AutoHotkey, post AutoHotkey help pages for beginners, create sample AutoHotkey scripts available for download, publish AutoHotkey e-books, and now I'm offering the third edition of this AutoHotkey overview e-book free. There is a lot of good information in this book for people trying to decide whether or not AutoHotkey is right for them. Since AutoHotkey's roots are in a program called AutoIt, I've added a chapter for those trying to decided which program to choose: AutoHotkey or AutoIt. (In short, other than language syntax, the major difference between AutoHotkey and AutoIt is that there is much better support for hotkeys which add action shortcuts and hotstrings—primarily text replacement—in AutoHotkey. This is what most beginners and casual users want.) But remember, regardless of which route you take, if you don't do anything else, you ought to do at least one or two of the AutoHotkey tricks offered here on your Windows computer.

AutoHotkey Tricks You Ought To Do is broken up into two parts: the AutoHotkey things you ought to do on your Windows computer and a convenient reference section which includes the Table of Contents and Indexes from six of  my other AutoHotkey books. If you own any of my other AutoHotkey books, then this book can help you find which book has the answer to your questions by searching the Table of Contents and indexes included here for each book. That should be easier than searching all six books separately.

The Things You Ought To Do

Most of the things that you ought to do with AutoHotkey are simple (often one-line) scripts which will immediately give you results. A few of them get a little more complicated, but you shouldn't need any other books to implement most of these Windows tricks. All that's required is the free AutoHotkey program installed on one of your Windows computers.

Installing AutoHotkey

Installing AutoHotkey is as simple as downloading the program and running it. Probably the best way to download the current version (changed from AutoHotkey_L to just plain AutoHotkey) is go directly to the AutoHotkey Web site and click the Download button. From time to time you will see references to AutoHotkey_L which took over as primarily from the original AutoHotkey package. The current download has now taken on the original AutoHotkey name rather than AutoHotkey_L.

Version 2.0 Note: AutoHotkey 2.0-a is a release of AutoHotkey in the alpha stage of development. The goal is to clean up many of the redundant and confusing aspects of the current version. However, there may be a considerable loss of backward compatibility when using 2.0. (Many scripts found on the AutoHotkey sites will not run properly.) For now, it is recommended that new users stick with the current 1.1 release.

Once you have installed AutoHotkey, then there are plenty of free online sources of AutoHotkey information. I put together my AutoHotkey books for those people (beginners and intermediate users) who want a little more explanation and to act as references—although by no means do my books cover all of the power of AutoHotkey.

Writing Your First AutoHotkey Script

Once the main AutoHotkey program is installed, if you can open the basic text editor Windows Notepad, then you can write a script. You only need to copy one of the many scripts available on the Web, paste it into a Notepad window, and save it as an AHK file (MyScript.ahk). There are examples at the "Installing AutoHotkey and Writing Your First Script" Web page. Right-click on the filename and select Run Script to load the file.

If you want a portable script, then you can right-click on the same filename and select Compile Script to create a separate EXE file (MyScript.exe) which you can run on any Windows computer with a simple double-click—with or without the main AutoHotkey program installed. That means you don't need to install AutoHotkey on every Windows computer to use AutoHotkey scripts. Just compile it into an EXE file.

If you later need to change an AHK file, right-click on the filename and select Edit Script. The script will open with your default text editor—often Notepad.

The Power of AutoHotkey

Most of the examples included in this book are either hotstring replacements for adding text or hotkey combinations to execute tasks. These features are the basis for AutoHotkey and if this is all you do, it will serve you well. However, AutoHotkey can do so much more by building useful apps for your Windows computers. (Just like AutoIt, AutoHotkey has tremendous power for automating any Windows program.)

There is a set of Graphical User Interface (GUI) pop-up windows built into the software which can be used to create gadgets and widgets for a variety of tasks. For a taste of these capabilities, see "AutoHotkey Applications Contents and Index" in this book or the ComputorEdge article "A Beginner's Review of AutoHotkey Pop-up Windows" which includes images of most of the available GUI pop-ups.

The power of AutoHotkey goes far beyond the topics covered in my AutoHotkey books which are aimed at beginning and intermediate script writers. I have seen many advanced commercial quality apps posted (and free to use) on the AutoHotkey forums. These involve AutoHotkey commands and routines which access the inner workings and hidden mechanisms of Windows. I don't pretend to have the level of knowledge or skill to produce these apps, but I can certainly help newcomers. Plus, many of these same snippets of code can be used in other scripts without a full knowledge of how they work.

Reference Look Up For AutoHotkey Books

If you're wondering if any of my books might be right for you, review the Table of Contents and Index for each of the books in the back of this e-book. This should give you enough information to determine whether one of the books will be helpful.

If you decide to buy any of my books, I would prefer that you purchase them from the ComputorEdge E-Books Web site. You can get all three formats (EPUB, PDF, and MOBI) at ComputorEdge E-Books, plus we offer package deals. Of course, you should purchase wherever you feel most comfortable.

ComputorEdge E-Books also provides two downloads for each book and format purchased. This is done just in case there is a problem with the first download, but it also facilitates downloading the book directly to more than one device. (None of the books are copy-protected so it is relatively easy to copy the file to other computers and devices.) If you buy at ComputorEdge E-Books and run out of downloads, send us an e-mail and we will give you more downloads. Whenever I update a book, I announce it on Jack's AutoHotkey Blog Most online retailors automatically update your books, but if you purchased a book (or bundle of books) from ComputorEdge E-Books and have used up your downloads, we'll give you more to access the latest edition. (I usually include a contact form in the blog announcing the updated book.)

With the exception of any free books, we prefer that you not distribute copies to your friends and colleagues without paying for additional books, We know that some people will do that anyway. If you're the recipient of any such copies of paid volumes and you find them useful to you, then we would appreciate it if you would buy your own copy at ComputorEdge E-Books. If you don't find the books of value, then there is no need to pay for them. We don't want you to waste your money and would quickly refund any money paid if you purchased the books directly from us.

I have found a few places on the Web where the books have been pirated and made available as free downloads. While this is illegal, there is little that the average author can do about it. Plus, my philosophy is that people who download from these sites would never have paid for the book in the first place. If push comes to shove, I prefer that my books be easy to use (no copy protection) rather than limit them to only people who can make a decision sight unseen.

My goal is to help publicize AutoHotkey to all Windows users (whether they use my books or not). Since it's open source and free to the world, there is no marketing arm to help promote AutoHotkey's value. (AutoHotkey is recognized for its usefulness and promoted by many of the top technical writers on the Web.) It's growing in popularity and many people use AutoHotkey extensively in their professions. In a world that is still dominated by Windows computers, AutoHotkey is a must have tool.

Chapter One: Add Tailored Signatures to All E-mail and Documents

“If you do nothing else, use AutoHotkey to put your signature in every document, blog, and e-mail.”

Add your formated signature (with e-mail and Web site) to any document, Web page response, or e-mail with easy one-line AutoHotkey scripts. Plus, instantly enter your e-mail address anywhere (no matter how long it is).

There are simple beginning AutoHotkey tricks that anyone with a Windows computer can do. If you need to regularly add your signature to documents, e-mails, or Web comments, then you're going to like this one. See Figure 1.

Figure 1. The signature (including company, title and Web addresses) is added to this e-mail by merely typing "jsig" followed by enter, space, or other punctuation. It also works in other Windows documents, program editing fields, and Web pages.

The AutoHotkey tips discussed in this chapter are based upon one of the basics of the free utility software—auto-replacement of text. They are simple to do and will save you a great deal of typing while personalizing all of your documents and correspondence in any form. These techniques work in any version of Windows including Windows 8 and Windows 10. Yes, they even work in the editing fields of the Windows 8 Modern Interface apps.

Adding Your Signature to Anything

The two basics of AutoHotkey (before entering the more complex uses of AutoHotkey pop-up windows) are hotkeys and hotstring replacement. Hotkeys are used to assign computer keyboard combinations (all keys pressed simultaneously) to certain operations. Hotstring replacement is primarily the substitution of strings of text entered from the keyboard with alternative text—usually to expand short abbreviations into longer input. For example, expanding "lol" into "laugh out loud." Here we use hotstring replacement to enter my signature after typing only a few characters. It can be done with one line of code in an AutoHotkey script::

::jsig::Jack Dunning{return}Publisher

{Return}ComputorEdge Magazine

{Return}http://www.computoredge.com

{return}http://www.computeredgebooks.com

(Although this line appears as four lines for display purposes here, it should be one continuous line in the script.)

This one line added to an AutoHotkey script does the job. If you know how to use Notepad and have the free AutoHotkey installed on your computer, you're ready to go. Anytime I type "jsig" into an e-mail, document, Web blog or other text editing field followed by a space or other punctuation, it's replaced with the following:

Jack Dunning

Publisher

ComputorEdge Magazine

http://www.computoredge.com

http://www.computeredgebooks.com

This technique is even more useful if you use multiple signatures. For example, I can add two more alternative signatures with:

::dsig::Paternalistically,{enter 2}{tab}-Dad

::gsig::Entirely yours,{enter 2}{tab}-GrandDad{enter}{tab}{space}"Too Cool for School"{!}

which, when "dsig" is typed, it is replaced with:

Paternalistically,

-Dad

and, when "gsig" is typed, it is replaced with:

Entirely yours,

-GrandDad

"Too Cool for School!"

However, you may not want to use {tab} since in Web pages it will move the cursor to the next object which could cause you to jump out of the edit field. A better option is to use {space 5}:

::dsig::Paternalistically,{return 2}{space 5}-Dad{return}

::gsig::Entirely yours,

{enter 2}{space 5}-GrandDad{enter}

{space 6}"Too Cool for School{!}"

(The second hotstring is wrapped into three lines for display purposes. In the script it would appears as one line.)

The number inside {space 5} indicates how many times to repeat the character.

How It Works

The hotstring replacement or substitution command has two parts: the characters which, when typed, trigger the replacement and the text that replaces the trigger text. The replacement command line always starts with two colons (::). (There can be option characters inserted between the two colons, but in its most basic form the string replacement command needs no options.) The triggering string follows the first set of two colons and is then followed by an additional set of two colons. The replacement string of text follows the second set of colons. When the trigger text is typed followed by a space, return (or enter), or other common punctuation character, that text is replaced with the substitution string. For example, the hotstring command:

::lol::laugh out loud

replaces the text "lol" with "laugh out loud" whenever "lol" is typed and followed by a terminating space, return, or most other punctuation.

Special keys such as the space bar, enter (or return) key, and tab are added by enclosing keywords in curly brackets ({space}, {enter} or {return}, and {tab} respectively). See the online documentation for other special keys and characters. Special characters such as the exclamation point (! for the ALT) also need to be enclosed in curly brackets when not acting as a hotkey modifier. Note the {alt} in the gsig hotstring above is replaced with the exclamation point (!). See the documentation for the Send command for a list of these characters.

Adding Blocks of Text

If you're adding a long block of text it's unreasonable to attempt to put it all in one line. In fact, in many cases it much easier to use this alternate method for adding signatures:

::jsig2::

(

Jack Dunning

Publisher

ComputorEdge Magazine

http://www.computoredge.com

http://www.computeredgebooks.com

)

By enclosing the entire formatted text in parentheses, AutoHotkey substitutes the raw text for the trigger string appearing as it does in the snippet of code. Notice that none of the special characters need enclosing in curly brackets. This example yields the same results as the first one-line example jsig.

For gsig signature, the block replacement command looks like this:

::gsig::

(

Entirely yours,

-GrandDad

"Too Cool for School!"

)

Caution: if you embed the TAB character in the text, even though you can't see it, it will still cause the cursor to jump to the next field when used in a Web page edit field.

By using parentheses to enclose blocks of text, substantial portions of commonly used boilerplate can be condensed to short hotstrings. This may be your preferred method for adding signatures to all of your Windows documents, since it is substantially less complicated than putting all the text on one line and using curly brackets for special keys and characters as shown in the first examples.

If you have any reason to add signatures to any of your Windows correspondence, blogs, and documents, then this is one AutoHotkey technique you should be using.

Note: AutoHotkey hotstrings offer much more capability than shown in these simple examples, such as, adding pop-up selection menus and running other apps. For more on the built-in hotstring options, see Beginning AutoHotkey Hotstrings.

Next time, how to instantly add e-mail addresses, user names, and possibly passwords to data fields.

Chapter Two: Use AutoHotkey to Instantly Insert Your E-Mail Address into Web Forms

“If you do nothing else, shorten your e-mail address to a simple hotkey or hotstring.”

It can be a pain to type long, convoluted e-mail addresses. Use AutoHotkey to instantly add yours and maybe your password too.

Hotstrings for Entering E-mail Addresses

As I look at all the ways that I routinely use AutoHotkey, some of the most useful are the simplest. I find that since so many Web sites use the e-mail address for account sign in, I'm often entering my e-mail address into the username field. Some pages let you store the username by saving it in a cookie. Others make you re-enter it every time. Most browsers have the capability to save usernames for each Web site, yet, even though I use those built-in save features, I find that I'm often having to type in my address. No matter how long your e-mail address, it's always awkward to type. The @ sign causes the problem. For some reason I can't remember the location of each punctuation key in the top row of keys. Not only do you have to look for the @, but the SHIFT key needs to be included in the process.

To make the e-mail address problem worse, they are usually unreasonably long—often with odd combinations of characters. It takes a long time to learn to type "computoredge.com" as all one word (and put that strange "o" in it). For many people the situation is worse. That's why this simple AutoHotkey technique is one of the most used features of my scripts. With it I can convert any e-mail address of any length into a two character word which instantly expands into the full address without adding any trailing space. (It's important that no space or return be tacked onto the end of the e-mail address as many accounts won't recognize a username with a trailing character.)

Fortunately this instant e-mail address feature can be implemented with AutoHotkey in one line by adding an option to the hotstring format:

:*:j@::mrjackdunning@computoredge.com

An option is included in the hotstring line by placing the appropriate parameter between the first two colons, in this case the asterisk (:*:). This asterisk immediately activates the replacement action when hitting the @ character. With the asterisk option included, AutoHotkey requires no space or other terminating character to initiate the hotstring action. Plus, if the combination is preceded by any character other than a terminating character (space, comma, return, period), then it does not fire at all. That means if I type another e-mail address which happens to have a "j@" in it, it won't fire. For example, ritaj@wizziwig.com would not convert the "j@" to "ritamrjackdunning@computoredge.comwizziwig.com."

I know…I'm still using the awkward-to-type @ character, but there is a good reason for that. There are almost no words that would start with "j@" (none off the top of my head). By using @ in the two character combination, I greatly decrease the risk that the e-mail address replacement will trigger while I'm typing another word. Of course, any unusual character would do.

If you check out the documentation for hotstrings, you'll see that there are a number of possible option characters which can be inserted between the first two colons including no automatic erasure of the hotstring (b0), capitalization sensitivity (c), omit the last character (o), and a few others.

Note: For more on how AutoHotkey hotstrings options can improve your Windows life, see Beginning AutoHotkey Hotstrings.

Adding a Password

You may or may not want to add passwords to your e-mail address or username to recreate an automatic login. On the downside, passwords appear in the AHK file as plain text. Anyone who has access to your computer could conceivably read your AutoHotkey login script. Even if you compile the file, it is still possible for someone to recover passwords by opening the EXE file with a program as simple as Notepad. While most of the file will appear as garbage, anything that was entered as plain text (the passwords) will appear as such somewhere in the file.

On the plus side, people will not necessarily know where to look for the logins as long as you don't use an obvious filename such as passwords.ahk. Plus, even if someone happens to come across your passwords, as long as you don't indicate which passwords apply to which account, then the nefarious person accessing your computer will need to figure it out. Whether you use this technique or not is entirely a matter of how comfortable you feel about someone else getting on your computer. If you save passwords in a browser, you run the same (or greater) risk since anyone on your computer can log into your accounts by merely opening the login page. For that matter, a person can go into Settings in Chrome, or Firefox, and see both the Web site and the password by merely clicking "Show" next to the saved password—although usually required to enter your Windows password. At least with AutoHotkey the villain would need to know which hotstring (or hotkey) to use with which site (unless you use the same password for everything).

Even if you used an AutoHotkey function to encrypt the passwords, it would require a key. Anyone who could access your files would be able to decrypt the passwords using the same key found in the AHK file.

That's your warning. If you feel safe then you can do a complete login with the following type of code:

:*:a1@::myaccount@computoredge.com{tab}YourPassword{return}

In this case, the instant that "a1" is typed it will be converted to the username "myaccount@computoredge.com", jump to the next field ({tab}), enter the password "YourPassword", then press the RETURN (or ENTER) key. It's that simple! You can set up all your logins in this manner using a different hotstring for each. The problem is that you will still need to remember which hotstring is which. Maybe you can write them on a piece of paper in some sort of code.

This same technique can be used to fill in name and address fields on forms, as long as there are always the same number of fields in the same order. Just use {tab} each time you need to jump to another field.

Tip: In a browser, you can quickly move data to the proper field by highlighting it and dragging it to the new location.

Logging in with Different Web Pages

I recently received the following AutoHotkey question:

I have some sites that put the username and password on different pages. So I modified the script as follows:

:*:a1@::username{return}password{return}

However, I need to pause after the first "return" until after the second page loads (i.e. the password page). Also, I'd like to precede the username and password with a line or lines in the same script so that it will first open the browser to the username page automatically. How do I accomplish these two things?

Ron Cerrato

There are many sites which change pages between entering usernames and passwords making the first script nonfunctional after the first page. The problem is that the script continues to run while the next page loads, thus losing the password to outer space. My first thought may be to use the Sleep command. (Remember, the Sleep command placed at key points in a script is used to slow down the execution of an AutoHotkey script. This prevents the execution of the lines of code from outrunning the action of the commands and the loss of subsequent functionality.) The Sleep command could be used to pause the script while the new page loads, however Web page loading times vary considerably—sometimes as long as a few seconds. If the page has not loaded by the time the Sleep command times out, the password won't get inserted in the second page.

The WinWaitActive command is also unreliable in this situation since a Web page may be active, yet still loading data. This will also cause the script to continue before it can enter the password in the data field.

An easy way to ensure that the Web page has completely loaded is to force the script to wait for user input with the MsgBox command:

:*:a1@::

SendInput, username{return}

MsgBox, Wait for next screen!

Sendinput, password{return}

Return

This does require you to press the ENTER key once when you see the new page has loaded, but it's better than re-entering the password after the script misses it. (There may be more elegant ways to solve this problem in AutoHotkey, but this certainly works and is simple.)

Note: When running multiple commands, the hotstring format must switch from the one-line hotstring format to the command structure format starting on the second line, then terminated with the Return at the end of the snippet.

As for loading the Web browser first, that's as easy as copying the URL from the Web login page and loading it with the Run command at the beginning of the script:

:*:a1@::

Run, https://www.website.com/loginpage.html

MsgBox, Wait for next screen!

SendInput, username{return}

MsgBox, Wait for next screen!

Sendinput, password{return}

Return

Again, with the variable times for loading Web pages, it may be easiest to use a MsgBox to suspend script execution.

Just in case the right Web page is already active, you may want to make the Run conditional with the IfWinNotActive command:

:*:a1@::

IfWinNotActive, [WinTitle]  ;WinTitle as shown by Window Spy

{

Run, https://www.website.com/loginpage.html

MsgBox, Wait for next screen!

}

SendInput, username{return}

MsgBox, Wait for next screen!

Sendinput, password{return}

Return

As discussed in Chapter Six, the window title can be found by using Window Spy after loading the Web page. This prevents the browser from attempting to reload an active page. The cursor must land in the username field.

*                    *                    *

Ron Cerrato and I exchanged e-mails about the problem of using AutoHotkey for logging in when the operation spans two Web pages—one for the username and one for the password. While the method for using MsgBox command worked for me on my bank site, the loss of focus caused by MsgBox prevented complete input for Ron. Eventually, he went back to using the Sleep command. I had avoided the Sleep command because the Web page loading times are hard to determine. Ron solved the problem by using very long Sleep times (7.5 seconds and 5.0 seconds). Here's Ron's final e-mail:

Thanks a lot!!! This works great:

:*:a1@::

Run, https://mybank.com/obc/forms/login.fcc

Sleep, 7500

SendInput, username{return}

Sleep, 5000

Sendinput, password{return}

Return

Third Edition Update: Chapter Fifteen, "Tracking the Original Edit Window," of Beginning AutoHotkey Hotstrings offers a sure-fire technique for saving the current page, then later returning to it using the WinActive() function and the WinActivate command.

Ron states:

I now have five green "H's" in the System Tray: Login, Autocorrect, Reminder, Dictionary, StripAllReturns.

This last comment about five separate AutoHotkey scripts running simultaneously brings up an important question. How many is too many? If all the green icons in the System Tray don't bother you, then there is nothing technically wrong with running a number of separate scripts. One advantage of doing this is that each app is less likely to conflict with another. However, if you want to combine scripts, then there are a few things that you need to understand about how AutoHotkey processes scripts.

In the AutoHotkey Applications book, I devoted Chapter Thirty-seven, "Combining Apps into One Script" to this problem. Rather than repeat what I said in that chapter I wrote a short piece with a slightly different take at this ComputorEdge AutoHotkey page How an AutoHotkey Script is Processed. This information is important because it often determines whether or not a combined script runs properly. Although beyond the scope of this book, an understanding of how AutoHotkey processes scripts when first loading helps you debug many scripts—even if they are standalone apps.

You can find even more detailed descriptions of how AutoHotkey processes scripts at Jack's AutoHotkey Blog.

Chapter Three: Use AutoHotkey to Instantly Turn Hard-to-Type Jargon into Hotstrings

“If you do nothing else, use AutoHotkey to instantly turn hard-to-type jargon into hotstrings.”

Most people have specialized vocabulary in their occupation. Use short hotstrings to add those terms to any document without spelling or typing hassles.

Anyone who regularly works with computers finds that frequently they must add specialized vocabulary to their writing and data fields. Often these terms—unique to the occupation—are too long to type so we abbreviate them for ease of input. However, these abbreviations may be confusing to some and meaningless to others. The answer is to add the complete terms to your documents every time you need them without typing anything more than an abbreviation. Then people will know exactly what you're talking about.

For example, typing ComputorEdge is a real pain. Between the capital E in the middle of the word and the silly "o" rather than an "e" it is extremely awkward to type. I could abbreviate ComputorEdge to CE, which may work find for most ComputorEdge readers, but to the average person CE may mean Consumer Electronics, CE marking, Continuing Education, or the Corps of Engineers. At a time when clarity is important, abbreviations get in the way.

I added these often used, yet specialized, words to my main AutoHotkey script which launches every time I log in:

::ce::ComputorEdge

When I enter "ce" followed by a space or other punctuation, I get ComputorEdge.

Here are a couple more terms I regularly use:

::ahk::AutoHotkey

::ahkl::ahkscript.org

Since I do an AutoHotkey blog, I often use the word AutoHotkey. I could use the abbreviation AHK, but that could be confused with Acid House Kings (Swedish band) or American Health Kennels. (Okay, maybe that one would work.) But even more useful is the second hotstring, "ahkl", which is replaced with "ahkscript.org" when followed by an ENTER key. I use this when I'm adding Web references to AutoHotkey commands.

Third Edition Update: Since the main AutoHotkey site has moved back from ahkscript.org to www.autohotkey.com, I no longer need the ahkl hotstring. Don't worry. The old ahkscript.org redirects to autohotkey.com for commands and other documentation. I no longer need to use the technique which follows, but the information is useful for other similar problems.

Before the switch back to autohotkey.com, if I Googled an AutoHotkey command, I would usually get a results list with the documentation for the original AutoHotkey version at the top. I could use that Web page, but command explanation may not be complete for the latest accepted version of AutoHotkey_L. I could search specifically for the AutoHotkey_L documentation, but that's time consuming compared to using the following technique.

I search for "AutoHotkey gui" with Google—usually by highlighting the words in a column I'm writing, right-clicking and selecting "Search Google for 'AutoHotkey gui'." I click "GUI - AutoHotkey" which is at the top of the search results, opening the GUI documentation on the original AutoHotkey site (www.autohotkey.com) (see Figure 1). Since, with the exception of the domain name, the URL for the AutoHotkey_L documentation is normally identical, I highlight the domain portion of the address and type "ahkl" followed by a return.

Figure 1. A Google search for an AutoHotkey command will bring up the Web site pages for the original version of AutoHotkey at the top of the list.

The URL is replaced with the equivalent AutoHotkey_L Web site URL (ahkscript.org) and the browser is redirected to that page (see Figure 2). I now have the URL I want to use in my referencing of the command.

Figure 2. The browser is redirected to the Web site with the documentation for the currently accepted version of AutoHotkey (AutoHotkey_L).

I'm not sure how much use most people would have for this type of trick, but it sure saved me a lot of time when the AutoHotkey Web site confusion still existed. However, expanding commonly used abbreviations for jargon is certainly something that you should do on your Windows computer—both to save you time and add clarify for others. I'm sure that you have your own set of words that are normally a hassle to type/spell.

If you use the AutoHotkey AutoCorrect script (discussed in this ComputorEdge AutoHotkey page and Chapter Twenty-three, "Add AutoCorrect to Your Windows PC" of the Digging Deeper into AutoHotkey book) for commonly misspelled words (and you should), then you can just add your special vocabulary to the AutoCorrect hotstring list.

Chapter Four: Adding Currencies, Special Symbols and Fractions, Plus Today's Date

“If you do nothing else, use AutoHotkey to add the special characters you want to your keyboard.”

While there are other ways to add foreign currency symbols and special characters to your documents, files, and Web edits, nothing is easier than AutoHotkey. Or, instantly add today's date to any document.

Every once in a while I need to insert a special character into a document, but the key doesn't exist. My keyboard supports a dollar sign, but no British Pound (£) key or Euro (€) key. For math or casual estimates my keyboard lacks a plus or minus symbol (±). In marketing, it takes some computer gymnastics to add the registered trademark sign (®) or copyright sign (©). Would you like to be able to add the condensed ½ to any document or Blog rather that the three character 1/2? I often use the following AutoHotkey technique for adding symbols. For example, I was able to add the degree symbol (°) for range of view to an Oculus Rift VR helmet article without consulting the Windows Character Map (see Figure 1). (Run => CharMap to open.)

Figure 1. Windows Character Map (CharMap) can add special characters to your documents.

You can add all these special characters (and any others that you need) without making any changes to your keyboard. Use AutoHotkey's hotstrings to auto-replace short key sequences with the special characters you need. If you do nothing else with AutoHotkey, do this.

Automatically Adding the Special Characters to Documents and Editing Fields

The great thing about this AutoHotkey technique is that it is simple to do. All you need is a short text file with as little as one line of code. The following is a list of some of the special hotstrings I use. For currencies:

:*:pound*::£

:*:euro*::€

:*:yen*::¥

:*?:cent*::¢

A hotstring replacement line always contains two sets of double colons (::). The first set of colons starts the hotstring line and may contain option code letters between the first two colons such as the * and *? seen above. The hotstring and replacement characters are separated by the second set of double colons (::). After loading the script, whenever typing pound*, £ appears; after entering euro*, € replaces it; add the ¢ sign to any document by typing cent*.

The asterisk * option between the first two colons forces hotstring execution immediately after pressing the last hotstring character (in this case it happens to be another asterisk *). This eliminates the need to hit a punctuation key or spacebar to activate the replacement. Since a number (which does not activate a text replacement) usually follows a currency symbol, the added * option ensures an action which would not normally occur.

The second asterisk acts merely as an activator, not to be confused with the first option. The additional asterisk at the end of each hotstring creates a unique hotstring using a character (*) you would not normally type. This helps prevent the accidental insertion of the special characters at unexpected times. For example, without the asterisk as part of the pound* hotstring, you would get the £ symbol every time you typed, "I want a pound of flour," ("I want a £ of flour"). I'm not likely to type the word "pound*" with an asterisks unless I want the £ character.

The question mark ? option between the first two colons forces the hotstring replacement to occur even when in the middle or at the end of another word. This is especially important for the cent sign ¢ since it normally will fall at the end of a number without any intervening space. (The order of the options, :*?: or :?*:, make no difference.)

When writing the script, you can use Windows Character Map to copy the symbols and paste them directly into the script text file.

See a few of my other special hotstrings:

:*?:+-::±     ; plus or minus sign

:?*:(c)::©

:?*:(r)::®

:?*:(tm)::™

:*?:`.` `.` `.::…  ;  ellipsis

The plus or minus sign is cool because all you need to do is type the plus (+) sign then the minus (-) sign. It instantly converts to ±.

I picked (c), (r), and (tm) because those are the character strings used for copyright, registered trademark, and trademark on a typewriter.

In the last example, I use three periods with spaces between them to create the ellipsis character (…). Since both the period and space are activating characters, I must use the accent/backtick escape character (`) before each in the hotstring. I could have eliminated the spaces in between, but I didn't want ellipses to start popping up each time I typed a number of periods in a row—although I can't remember the last time I did that.

For the few fractions available and other symbols I added:

:*:1/4*::¼

:*:1/2*::½

:*:3/4*::¾

:?*:deg*::°

Since I had previously implemented the AutoHotkey AutoCorrect script for the most common misspelled words (discussed in the Digging Deeper Into AutoHotkey e-book), it was easy to add these lines to the end of the file. That way I didn't need to run a separate script for the symbols.

Tip: If you want to prevent the activation of a hotstring, click a mouse button before you complete typing the activating hotstring. The click resets the hotstring monitor.

If there's only one special character that you need readily available, then that's all you put into the AutoHotkey script. You can also compile the script into an EXE file which will run on any Windows computer. That eliminates the need to install AutoHotkey on every machine you use.

If you want to eliminate the steps involved in finding and using certain special characters, then this is an AutoHotkey trick that you really should use.

Third Edition Update: Even though the hotstring examples above are relatively easy to remember, I still find that I occasionally need to go back and remind myself how to add them. When writing the book Beginning AutoHotkey Hotstrings, I developed a script for adding special characters through a pop-up menu. See Chapter Ten, "Add Currency (and Other) Symbols with AutoHotkey Hotstring Menus." If you need to quickly add a number of different types of symbols, then a selection menu may be your best bet.

Tip for Adding Today's Date to Any Document

A similar, yet slightly more complicated, use of AutoHotkey makes a text hotstring string act as a hotkey—running a series of commmands. Valuable in those situations where the results may vary, the hotstring adapts to the current situation. In this example, AutoHotkey instantly enters today's date (formatted Month, Day, Year—e.g. June 27, 2016) into the document whenever you type the text string Anow:

:c*:Anow::

FormatTime, CurrentDateTime,, MMMM d, yyyy

SendInput %CurrentDateTime%

Return

To run commands using a hotstring, the first code must appear on the next line after the hotstring definition (:c*:Anow::)—treating it as a command rather than replacement text. In this case, I used Anow (with a capital A) because it is not a word and unlikely to appear in any text, especially since the first letter is capitalized. By placing the c option between the first two colons (:c*:), AutoHotkey requires the hotstring to contain the same capital letter (case sensitive). This reduces ambiguity and the likelihood of accidental firing when entering the hotstring.

The asterisks between the two colons (:c*:) tells AutoHotkey to execute the command immediately when pressing the last letter without any terminating keystroke such as a comma or period. This hotstring formats the current date (by default) and sends it to the active document or text editing field. The hotstring in terminated with the Return command on the last line. This and similar techniques are discussed in Chapter Twenty-six of the AutoHotkey Applications e-book.

Chapter Five: Web Site Searches Made Easy

“Set up a hotkey combination to make searching your favorite Web site easy with AutoHotkey.”

Anyone can put this simple AutoHotkey script to good use for quickly searching their favorite Web site. Plus, in this chapter we build a slightly more advanced app by using a graphic user interface (GUI) and Menu command to add more bells and whistles.

Often when researching a topic, we just open Google in our browser and do a keyword search. This is easy enough and yields a plethora of results—sometimes too many. If we already have our browser open, we can usually highlight text, right-click, selecting search, then finding the selected text with our default search engine. But what if we use an application that doesn't support a Web search or would like to find the selected text in a particular site such as Wikipedia? A simple AutoHotkey script provides us with a hotkey combination that directly executes the search function for a specified site. For example:

^#g::

Send, ^c

Sleep 200

Run, http://www.google.com/search?q=%ClipBoard%

Return

After loading on a Windows computer with the free AutoHotkey software installed, this snippet of code, when saved in a simple text file (use Notepad or any other text editor) with the AHK extension (e.g. GoogleSearch.ahk), initiates a Google search for the highlighted text in any Windows program whenever simultaneously pressing the CTRL+WIN+G key combination (Control++G). If your default browser is not open, the script opens it.

The three characters (^#g) before the double colon set up the hotkey combination (Control++G) for initiating the routine. Once the script is loaded, the routine runs every time the Control key (^), the WIN key (#) and G are pressed simultaneously on the keyboard.

The AutoHotkey Send command executes the Windows key combination CTRL+C (the copy command) placing the selected text into the Windows Clipboard for later use.

Although omitted from many examples that you may find on the Web, the Sleep 200 line of code is important. Without it, you may need to hit the hotkey combination twice. The reason is that the computer needs some time to copy (CTRL+C) anything into the Windows Clipboard—however short. Using the Sleep command allows a pause (200 milliseconds) before moving on to the next step in the script. Otherwise, the script may run so fast that it attempts the search with the previous contents of the Clipboard.

The line of code with the Run command is the heart of the script. It opens Google and executes a search using the contents of the Windows Clipboard. Not coincidentally the word ClipBoard, a built-in AutoHotkey variable, always contains the contents of the Windows Clipboard. It can be evaluated and used in other commands by placing percent signs around it (%ClipBoard%). Doing this substitutes the saved text in the Windows Clipboard for the term %ClipBoard% in the Run command line .

The Return command at the end of the line merely marks the end of the routine. That's it!

If you wanted a similar hotkey combination for Wikipedia, then it might look like this:

^#w::

Send, ^c

Sleep 200

Run, http://en.wikipedia.org/wiki/Special:Search?search=%ClipBoard%

Return

I've seen on the Web similar examples of this script which place all of the commands on one line. Be warned that this will not work since multiple commands must appear on separate lines after the initial hotkey combination (marked by the double colon) and enclosed with a Return. However, a sole command appearing immediately after the double colon (such as the Run command) will execute while requiring no Return command—as long as it is the only command.

Setting Up Your Own Favorite Web Site Search

The hardest part of setting up your own specialized Web site search is determining the URL (Web address plus search parameters) that you should use. Suppose you want to set up a hotkey combination to search your favorite recipe site—in this case Food.com. Open your browser, navigate to your favorite site and do a search using their built-in search tool. After the search, the URL with the included search parameters will show up in the navigation field (see Figure 1).

Figure 1. The navigation field of your Web browser will display the parameters needed to execute a search of the site.

In this case, Food.com merely adds the name of the food to the end of the search URL. The following snippet will execute a recipe search:

^!r::

Send, ^c

Sleep 200

Run, http://www.food.com/recipe-finder/all/%ClipBoard%

Return

Note that the entire URL is copied (including the http://) with only the search keyword being replaced with %ClipBoard%. It's that simple. Now, after loading, whenever you highlight a food item on your Windows computer in any document or Web page and hit CTRL+ALT+R simultaneously (! is the ALT key), a recipe search of Food.com will be conducted using the selected food.

But it's not always convenient to highlight the food item—especially if you're not in a document or on a Web page which contains the words. Unlike Google or Wikipedia which you might want to use whenever you come across curious words in a document or on a Web page, you're not likely to have the proper words available for highlighting when you're searching for a new recipe. Wouldn't it be better just to input the food into a window (such as the one displayed on the left), then immediately search for the recipe? Next we will look at the few lines of code needed to open an input window for entering the recipe keyword search. It's simple and only takes three additional lines of AutoHotkey code.

Making a Pop-up Search Window

As novice AutoHotkey users we tend to confine ourselves to building hotstrings and hotkeys (such as found in this "Introduction to AutoHotkey") or the previous easy Web search script. But we are only one step away from adding professional pop-up windows to our quick apps. In many cases, adding an AutoHotkey pop-up control can turn a good tool into a great tool.

Above a short, easy script for launching favorite Web page searches of highlighted keywords is demonstrated. Finally, Food.com is the target of searches for recipes. However, it's unlikely that we will just happen to come across the right recipe keywords unless we are reading an article about a particular food. Wouldn't it be nice to pop up an input box (as shown above), type in the recipe keywords, then launch the search? Here is a new script which adds a search word input pop-up:

Gui, Add, Edit, vMySearch

Gui, Add, Button, Default gSearch, Search

Return

^!r::

Gui, Show

Return

Search:

Gui, Submit, Nohide

Run, http://www.food.com/recipe-finder/all/%MySearch%

Return

While this new script has only a few more lines than the original, it is organized in a slightly different manner. The first two lines (which must appear first in the script) create the GUI (Graphic User Interface) window which allows user input. The hotkey combination CTRL+ALT+R (^!r) now merely displays that newly created input window with the Gui, Show command. Then the subroutine (label) called Search: does the work of saving the user input to a variable (MySearch), opening the default Web browser and running the Web page search with the user inputted keywords.

While a more detailed explanation of how this script works follows, as a beginner someone could merely substitute the URL and search parameters for their favorite Web site into the Run command line (as discussed in the beginning of this chapter) to add this search pop-up window capability to their favorite AutoHotkey search script.

The AutoHotkey GUI (Graphic User Interface)

The AutoHotkey GUI (Graphic User Interface) consists of a powerful set of tools for making pop-up windows. While they may be a little intimidating for the novice, they implement a new level of capability to even the simplest scripts. GUIs add editing and input fields, buttons, lists, dropdown menus, and many other objects which enhance the usability of AutoHotkey. The GUI pop-ups do have their peculiarities, but once understood they can be simple to use. The GUI shown above, which consists of a text input field and a button to start the search, is about as easy as it gets. It is a good start for any AutoHotkey beginner who wants to move to the next level.

The GUI command consists of sub-commands for setting up a pop-up window. The three most important sub-commands are Add (Gui, Add) which places objects in the pop up window, Show (Gui, Show) which makes the window pop up onto the screen, and Submit (Gui, Submit) which captures any input (text, menu selections, etc.) from the user.

When using the Gui, Add command there are various objects which can be included in the window such as Text, Edit, Button, etc. (To see what many of the objects do and look like, check out this ComputorEdge AutoHotkey page.) For our easy search script we only need an Edit object (Gui, Add, Edit) for inputting the recipe key words and a Button object (Gui, Add, Button) for starting the search:

Gui, Add, Edit, vMySearch

Gui, Add, Button, Default gSearch, Search

These two lines actually place the GUI into computer memory although they are not be immediately displayed on the screen. (For the pop-up to display as shown above, the Gui, Show command must be used.) These two lines should appear in the first part of the script before any hotkeys or subroutines. This first part of every AutoHotkey script is called the auto-execute section and runs when the script is first loaded. If they appear after any hotkeys, they will not run. (These GUI setup lines may appear within a hotkey combination, but this may cause errors as discussed below.)

Note: When we start adding more than just hotkeys and hotstrings to an AutoHotkey script, it's important to understand how AutoHotkey scripts are read by the computer. See this AutoHotkey page and these blogs for a better understanding of how AutoHotkey reads a script.

An important concept in AutoHotkey GUI windows is that once one is created it continues to exist in memory whether or not you can see it (or maybe even close it with the little "x" in the upper right-hand corner). This means that you can bring it back with the Gui, Show command. If you want to remove it permanently, then you must either destroy it (Gui, Destroy) or exit the AutoHotkey script (ExitApp).

There are numerous options available for every GUI command, but we don't need to deal with most of those in this beginner script. The two options of interest are vMySearch in the Edit line and gSearch in the Button line. These options demonstrate a couple of the more important AutoHotkey concepts which apply to most GUI commands and objects. An understanding of how these two work aids you later when exploring other powerful possibilities with GUI windows.

The vVariable Option

In a Gui, Add, Edit line, the letter "v" in front of a variable name (any name you choose) in the option area (after the third comma) creates a variable by that name. When the Gui, Submit command is issued, any input from the GUI objects is stored in the associated "v" variable. In this case, MySearch is the "v" variable where the entered search words will be stored. Rather than using the selected words stored in the Windows ClipBoard (as was done previously), the script now uses the input stored in MySearch.

A particular vVariable can only be created once when a script is running. If you try to recreate the same variable by running the Gui, Add line with that "v" variable more than once, you will get an error. For that reason, it is important for the Gui, Add, Edit line to appear outside the hotkey routine. Otherwise after the first instance, an error will occur each time you use the hotkeys as it tries to recreate an existing variable. (There are other ways to avoid this error as discussed in the AutoHotkey Applications e-book such as using Gui, Destroy at the end of the routine, but most often placing the Gui, Add lines in the auto-execute section at the beginning of the script will be cleanest.)

The gLabel Option

In the Gui, Add, Button line, the letter "g" (for goto) in front of a name (any name you choose) in the options area (after the third comma, but before the fourth comma) designates a subroutine (label) for the GUI to run when the object is clicked (or changed—depending upon the type of object). This is used to add action to a GUI. In this case the option gSearch calls the label (subroutine) Search: . (Note that the first line of the actual subroutine (label) is always its name followed by a colon ":" while the last line is the Return command.) In this case the label (Search:) first uses the Gui, Submit command to save the user input to the variable MySearch, then uses the Run command to execute the search using the contents of MySearch (%MySearch%). This is similar to the prior search line which uses %ClipBoard% rather than %MySearch% for the search keywords.

The Gui, Submit command saves all user input from all the GUI objects with a vVariable option to its associated variable name. The NoHide option merely prevents the pop-up window from disappearing from the screen after the Submit. If you want the window to close, remove the NoHide option from that line. (Remember, the pop-up will still be available in memory even if it is closed.)

If the gLabel option is used in a Gui, Add command, then the label (subroutine) must also exist. Otherwise, AutoHotkey will throw an error when loading. At a minimum, the label name (followed by a colon) must be included in the script somewhere (anywhere as long as it appears after the auto-execute section which is always in the beginning of the AHK script file).

The Hotkey Combination and Gui, Show

Note that the only line of code appears within the hotkey combination: Gui, Show. That's because the only thing we need to activate the GUI is to Show it. There is always a temptation to place all of the GUI commands inside the hotkey combination, but as pointed out above, this will likely cause errors when the hotkeys are hit a second time—unless the GUI is destroyed after the action is completed.

The logic of the script is:

1. The GUI window is loaded into memory.

2. The hotkey combination (CTRL+ALT+R) displays the pop-up GUI window.

3. Clicking the Search button, submits (saves) the user input and launches the search.

The script waits patiently between each step.

Many beginners confine themselves to creating hotstrings and hotkeys. There is nothing wrong with that as long as AutoHotkey is doing what they want it to do. The GUI objects may look confusing and they do have some quirks which must be considered. However using these graphic window objects brings AutoHotkey scripts to an entirely new level. A complete understanding of all of the possible GUI options is not necessary. The basic functionality of AutoHotkey GUI pop-ups is built into them and automatic without using many of the possible options. But most important are the vVariable and gLabel options demonstrated in this simple script which unleash most of the power that the GUIs have to offer.

Third Edition Note: AutoHotkey GUIs quickly create useful applications. The book AutoHotkey Applications demonstrates how each GUI type (MonthCal, ListView, TreeView, etc.) may be used in practical applications.

What if we don't want to be forced to remember the hotkey combination? Next, add this search feature to the right-click menu of the AutoHotkey icon in the System Tray with one line of code.

Adding an Item to the AutoHotkey System Tray Right-click Menu

In the first two parts of this chapter we've put together short AutoHotkey scripts which, first, start searches of specific Web sites by selecting words in any Windows document or Web browser, then hitting the assigned hotkey combination. Next, the script was modified to use a pop-up a window for entering the keywords before the search of targeted Web sites (see Figure 3). The next step, by inserting only one line into the script, adds the search feature as an option in the right-click menu of the AutoHotkey icon in the System Tray.

Figure 3. A pop-up was added to initiate searches of specific Web pages—in this case Food.com.

Placing items in the AutoHotkey System Tray right-click menu is easy with the Menu, Tray, Add command. Whenever this command is executed it places another item at the bottom of the menu. For example:

Menu, Tray, Add, Search Food.com, ^!r

places the text "Search Food.com" as an item at the bottom of the menu for the original script (see Figure 4).

Figure 4. The Menu command is used to place an item at the bottom of the AutoHotkey icon System Tray right-click menu.

The "Search Food.com" parameter is the text displayed in the menu item and ^!r is the hotkey combination (CTRL+ALT+R discussed above) which calls the routine. Selecting this option from the right-click menu has the same effect as using the hotkeys to start the search. This eliminates the need to memorize the hotkey combination.

Add that one line to the beginning of the last script and you get the following:

Menu, Tray, Add, Search Food.com, ^!r

Gui, Add, Edit, vMySearch

Gui, Add, Button, Default gSearch, Search

Return

^!r::

Gui, Show

Return

Search:

Gui, Submit, Nohide

Run, http://www.food.com/recipe-finder/all/%MySearch%

Return

It is really that simple!

Eliminating the Hotkey Combination

Maybe we don't want to use hotkey combinations at all? We can replace the hotkey with a label name which runs the same subroutine. In this case ^!r is replaced with the label RecipeSearch:

Menu, Tray, Add, Search Food.com, RecipeSearch

Now the script looks for the label (subroutine) RecipeSearch: when the option is selected from the right-click menu. Therefore, the hotkey combination must be replaced with:

RecipeSearch:

Gui, Show

Return

Here is the entire script with the hotkey eliminated:

Menu, Tray, Add, Search Food.com, RecipeSearch

Gui, Add, Edit, vMySearch

Gui, Add, Button, Default gSearch, Search

Return

RecipeSearch:

Gui, Show

Return

Search:

Gui, Submit,

Run, http://www.food.com/recipe-finder/all/%MySearch%

Return

You may think that you can do the same thing with the selected text Web site search technique with the same line of code. While you can add the option to the same right-click menu, a little more code is required to make it work. The problem is that when you right-click on the System Tray icon the original window loses focus and is no longer the active window. The copy function (CTRL+C) for saving the selected text to the Windows Clipboard will not work unless the window with the selected text is active. Therefore, before the script can run properly the last window must be reactivated.

While this is a little more complicated, the easiest way to resolve the problem is to use a combination of the two techniques above. A new label (RecipeSearch subroutine) is created for the right-click menu which activates the last window by sending the Windows hotkey combination ALT+ESC. This standard Windows hotkey combination cycles to the previous active window. This is done in AutoHotkey with the Send command (Send, !{Esc}). Then, using the same AutoHotkey Send command, the hotkey combination which activates the search is issued (Send, ^!r). In this case, we modify the Food.com search example above:

Menu, Tray, Add, Search Food.com, RecipeSearch

Return

RecipeSearch:

Send, !{Esc}

Send, ^!r

Return

^!r::

Send,^c

Sleep 200

Run, http://www.food.com/recipe-finder/all/%ClipBoard%

Return

Be sure to add the Return after the Menu, Tray line to mark the end of the auto-execute section of the script which runs when it's first loaded. Otherwise, the RecipeSearch: label will immediately execute on loading.

The problem of adding hotkeys which require a specific active window to right-click menus has confused many AutoHotkey users. While there are other AutoHotkey commands such as WinActivate which are designed to open the right window, I've found that simply using the Windows ATL+ESC combination which jumps back to the last active window is far easier than some of the other AutoHotkey gymnastics. For some AutoHotkey enthusiasts it's possible to become so consumed with AutoHotkey that they forget that there are many features built into Windows which will do the same thing easier and quicker.

Third Edition Update: As I mentioned in a Chapter Two, Chapter Fifteen, "Tracking the Original Edit Window," of Beginning AutoHotkey Hotstrings offers a sure-fire technique for saving the current page, then later returning to it using the WinActive() function and the WinActivate command.

I recently noted one person who was simulating the motion of the mouse with AutoHotkey to prevent the computer from going into the Sleep mode. He then wanted to run a program at a specific time. It seemed to me that it would be easier (and more reliable) to disable the Sleep mode and use Windows Task Scheduler to later launch the program. Sometimes we lose sight of the big picture. The goal is to do things the easiest way—whether it uses AutoHotkey or not.

For more detailed tips and tricks about AutoHotkey Hotkeys, see the e-book description found in this book by the same name.

Chapter Six: Hotkeys to Automate Right-click Menus

“Using the same right-click menu repeatedly? Protect from Carpal Tunnel with this AutoHotkey tip.”

If you have a right-click menu that you use over and over again, then you can save time and repetitive finger actions by setting up an AutoHotkey hotkey to get the job done. A tip for using the AppsKey to open the context menu—even if you don't have one on your keyboard. Plus, toggling features on and off.

This chapter contains useful basic information for automating right-click menus, however the AppsKey technique discussed at the end of the chapter contains a simple change that greatly simplifies this problem. While it may not work in all situations, it works much better for the example used in this chapter.

If you want to save yourself some mouse clicks, a possible contributor to carpal tunnel syndrome, in an often used right-click menu sequence, then you should turn your menu selections into AutoHotkey hotkeys. In many Windows programs, there are already hotkeys assigned for right-click menu options. In those situations, it's often easier to use those hotkey combinations rather than right-click, move down the menu, pop up the submenu, slide down the new menu, then left-click on the desired item. If nothing else, doing this mouse procedure over and over again becomes quite tedious. Especially, if you have to do it a lot. The problem is that some programs don't have hotkeys for selected options.

For example, in many e-mail client programs it can be useful to add certain domains to the Blocked Senders list to stop more junk mail from a specific domain. In the Windows 7 Mail program, this is done by selecting the received junk message, opening the right-click menu, sliding down to "Junk email", waiting for the next menu to open, then left-clicking "Add sender's domain to blocked sender list" (see Figure 1). Then any incoming mail from that domain is automatically moved to the Junk Mail folder. But there is no hotkey for adding the domain to the Blocked Senders list. The option and hotkey combination shown as "Mark as junk" merely moves the e-mail to the junk folder without any type of permanent remedy.

Figure 1. The sender's domain is added to the blocked e-mail list through the right-click menu.

To remedy this situation the following short AutoHotkey script can be used:

^!j::

Click Right

Sleep 200

Send, {DOWN 13}

Sleep 200

Send, {RIGHT}

Sleep 200

Send, {DOWN 3}

Sleep 200

Send, {ENTER}

Return

When loaded this script will execute the domain blocking for Windows Mail in Windows 7. It is not a universal script because it is tailored to the specific menu in Windows Mail. But that means you can easily change it to conform to any right-click menu in any Windows program.

Hotkeys are set up by adding specific key combinations to an AutoHotkey script followed by a double colon (::), followed by action command lines and terminated with the Return command. This places in memory a routine which will be activated every time the hotkey combination is pressed.

Note: You do need the free AutoHotkey program installed on your computer, but writing a script can be as simple as adding the code to a Notepad file with the .ahk extension. See "Installing AutoHotkey and Writing Your First Script."

To activate the action, the target e-mail must be selected in the e-mail list before pressing the CTRL+ALT+J (^+!+J) hotkey combination. (You may note that this is also the hotkey combination assigned to "Mark as junk." You can use any combination you like, but this will override the original combination so the hotkeys will both send the e-mail to the Junk folder and add the domain to the blocked list.)

Use the Click command (Click Right) to send a right-click to the mouse cursor location. This opens the right-click menu. But since the Click command is used, it's necessary for the cursor to remain within the e-mail list pane when the hotkey combination is executed. Otherwise, the right-click menu will open for wherever the cursor happens to be sitting (the Desktop or other window) with unpredictable consequences. (To prevent random right-click menus from a misplaced hovering mouse, a trick for blocking the routine when the cursor is not over the list of messages appears below.)

The Sleep command (Sleep 200) is added merely to pause the script while allowing enough time for the menu to open and become active. Otherwise the script may outrun the menu action and do nothing—or worse the wrong thing. The number of milliseconds used can vary based upon what your Windows system needs. Initially, you may want to slow down the script by making the delays longer (Sleep 1000 for one second) so you can see whether the proper menu items are being selected.

The Send command (Send, {DOWN 13}) is used to move the cursor down the menu to "Junk email." The number 13 added to DOWN simulates pushing the down arrow 13 times. It's important to get the number right. Otherwise the wrong option could be activated. That's the reason for slowing it down while testing. Then after the submenu automatically opens, the right arrow key is sent (Send, {RIGHT}). Down three more (Send, {DOWN 3}), then the ENTER key is sent (Send, {ENTER}) to execute the option. Don't use the Click Left command because at this point the actual mouse cursor could be sitting almost anywhere.

Preventing Action from a Wandering Mouse

This trick is a little more advanced and you don't need to do it if you're comfortable with keeping the mouse hovering inside the message list pane in Windows Mail. But it does protect against inadvertent right-click menus with wrong selections.

As noted above, the Click command will activate at the location of a hovering mouse. As long as the mouse is anywhere over the list of messages, then the Click Right command will act on the currently selected message. In order to prevent random right-click menus caused by a mouse wandering over other windows (or panes within Mail), the hotkey routine must be stopped from activating when the mouse is not hovering over the list of messages.

The AutoHotkey download includes a program called AutoIt3 Window Spy. After installation, it can be found in the AutoHotkey programs folder. This program is commonly used to identify specific information about active windows and controls within those windows for use in AutoHotkey scripts. Open Window Spy by selecting it from the Programs list, finding it through the Start Search field (Windows Vista or 7), or right-clicking on the icon in the System Tray for an active AutoHotkey script (.ahk) and selecting Window Spy from the menu (see Figure 2).

Figure 2. Window Spy shows that the Message List and a control class of SysListView321 when Mail is active and the mouse is hovering over the Inbox list.

Click on a message in Windows Mail (or whatever program you're using) and note the value of ClassNN in the Now Under Mouse Cursor section. This is the control id needed to isolate the routine—in this case SysListView321.

To isolate the routine to that control pane the following code is added to the script:

^!j::

MouseGetPos,,,, MailWindow

If MailWindow = SysListView321

{

Click Right

sleep 200

Send, {DOWN 13}

Sleep 200

Send, {RIGHT}

Sleep 200

Send, {DOWN 3}

Sleep 200

Send, {ENTER}

}

Return

The MouseGetPos command is used to grab the control id for whatever control is under the hovering mouse in the active window and store it in the variable MailWindow. Note that there are four commas used before the MailWindow variable name. They are all required, otherwise different information will be store in MailWindow (see the MouseGetPos command linked above).

Next, only if the variable MailWindow equals "SysListView321" will the rest of the right-click menu routine run. This prevents accidental firing of the routine when the mouse is in the wrong location—outside the message list pane.

Warning: If you accidentally add a domain, such as gmail.com, to the blocked domain list, then you won't see any messages from people who use that domain (e.g. Gmail). Periodically check the Blocked Senders list for domains that should not be blocked.

You may not need this script for making a hotkey to add domains to the blocked e-mail list, but this same simple technique can be used anywhere in any Windows program where a menu pops up with a right-click. If you find yourself repeating a mouse right-click procedure ad infinitum, then you should set up a hotkey combination with AutoHotkey. It's as simple as that. It's quick and may save you from carpal tunnel syndrome.

A Simpler, More Effective Technique

We've been working on an AutoHotkey script to automate the Windows Mail right-click menu when adding domain names of junk mail to the blocked list. It's part of my grand experiment to determine if I can reduce the volume of Spam that lands (and stays) in my Inbox. I know that I'm probably fighting a losing battle because spammers use a huge number of domain names for their addresses. I know it's not possible to stop them all (spammers can always add more addresses), but maybe I can slow down the flow.

The first step is to make it as easy as possible to add the bad domain names to the blocked list. The normal procedure is to right-click on the Spam listing then navigate to Junk E-mail => Add Sender's Domain to Blocked Senders List (see Figure 1). However, doing this for every piece of junk mail becomes tedious. A hotkey combination set up with an AutoHotkey script is much easier.

Figure 1. Right-click on the Spam to add the domain to the Blocked Sender's Domain List.

Above I used the Click Right command to open the right-click menu. The problem is that even after the first Spam header was selected, the mouse cursor must continue hovering over the same area of the window to activate the proper right-click menu. I added some code to prevent the wrong menu from opening if the mouse was hovering in the wrong place, but that merely prevented the menu from displaying at all when the mouse was moved away from the right pane. If the mouse wasn't hovering over the list, it still wouldn't work. The slight change to the script discussed next prevents the mouse location from affecting which context menu pops up regardless of the mouse cursor position.

The Windows Context Menu

There is another way to open the right-click menu without using the Click command. On many keyboards you'll find a menu key or applications key (pictured at left) which opens the default right-click menu for the active program window or pane within the window—often popping up in the upper-left hand corner of the active pane or over the selected item. This key once served an important purpose when the mouse only had one button. But since a click of the right mouse button on the proper place in the window serves the same purpose, opening the context menu, this key has fallen out of use for most people. Many users don't even know that it exists. On some keyboards it's necessary to push the menu key in combination with another special function key to open the menu—if it exists at all. The advantage to the menu key is that as long as the proper window (and pane inside the window) is active you don't need to use the mouse at all.

It's important to note that since the menu key is not sensitive to the mouse location, it cannot be used to open the context menus which are mouse position sensitive. For example, hovering over a Web link and hitting the menu key will not open the menu that's normally available when right-clicking on the link. Only the standard context menu for the active window pane will appear.

If most people don't use the menu key (and might not even have one on their keyboard), why bring it up at all? Because AutoHotkey has a keyname for the menu key (AppsKey) which can be used in conjunction with the Send command to achieve the same result. Send {AppsKey} can provide all the benefits of the menu key without ever locating or using the key itself.

In the example of blocking junk mail domains Windows Mail, now all that's needed is to click on the target e-mail header of the Spam and use the CTRL+J (^j) hotkey combination:

^j::

SendInput {AppsKey}

Sleep 100

Send, {Down 12}

Sleep 100

Send, {Right}

Sleep 100

Send, {Down 3}

Sleep 100

Send, {Enter}

Return

Now it doesn't matter where the mouse is located as long as the proper window pane is active.

Note: Don't use the ALT key (!) in your hotkey combination since the ALT key prevents the menu key from activating.

This script can be adapted to other context menus in other programs by adjusting the Down and Right parameters to the appropriate number for the new menus. It's a good idea to test the script while watching it with longer Sleep periods (say 1000 milliseconds or more). This slow-motion observation of the action ensures that the proper selections are enacted by the script. Plus, you might also remove (place a semicolon in front of the line of code) the Send, {Enter}command, which actually executes the selection, until after you know you have it right.

If you always left-click in the proper window pane before using the hotkey combination, then you can stop reading right here before I add any further complications to the code. The problem with writing any AutoHotkey scripts is that you can always add more features. But, often after you get the first 90% done, it's pretty much everything that you need. If you're new to AutoHotkey then you might work with the code above for a while before moving on to the following section. While the next part of this chapter does address a real issue, in most situations it's not likely to be a problem.

Caution: If you're using a script similar to the one above to block domains, check each message to make sure that the message isn't coming from common domains such as gmail.com or yahoo.com. This could cause e-mail from many of your friends who use one of those services to be blocked. If you do get Spam from a common domain, block the sender rather than the sender's domain.

Limit the Hotkey to the Proper Program

If the wrong program window is active, then the hotkey menu results are unpredictable. Another context menu may be activated with disastrous actions following. There are a couple of ways to ensure that the hotkey combination is only available when the right window is active. The first is the #IfWinActive directive. By placing #IfWinActive with the title of the window at the end of the script followed by the hotkey definition, the hotkey combination will only be in effect with the right type of active window. However, this does not prevent the wrong context menu from popping up if the wrong window pane (control) is active in that window. For example, Windows Mail has one pane with the various mail boxes, another with the list of e-mails received (this is the one we want), and the message view pane itself. Click in the wrong place and the wrong menu will respond to this script.

This last problem is resolved as it was in the earlier script by isolating the action to the correct pane, the e-mail header list. But this time we use the ControlGetFocus command rather than the MouseGetPos command. This also eliminates dependence on the mouse location:

^j::

ControlGetFocus, ActiveControl, A

If ActiveControl = SysListView321

{

SendInput {AppsKey}

Sleep 100

Send, {Down 12}

Sleep 100

Send, {Right}

Sleep 100

Send, {Down 3}

Sleep 100

Send, {Enter}

}

Return

The ControlGetFocus command saves the name of the active control (the e-mail list) to the variable ActiveControl. If it doesn't match the Windows Mail heading list (SysListView321), then it does nothing.

In truth you should be checking the domain of each e-mail before executing the block. Otherwise you might inadvertently block the wrong person. But, if you adapt this script to the context menu of another program for a totally different purpose, this may not be an issue.

*                    *                    *

The following is more advanced information for the AutoHotkey curious.

Finding Window Titles and Control Names with WindowProbe

Earlier in this chapter, Window Spy was used to find titles and control names. I put together another quick tool I call WindowProbe for capturing some of the same information in a different format. WindowProbe uses a tooltip help pop-up to display vital information as you move the mouse cursor around the screen (see Figure 3).

Figure 3. The WindowProbe app is an AutoHotkey script which displays the Unique ID, Title, Class, and Control under the mouse cursor, plus the name of the Active Control in a cursor tooltip message window.

A while back I highlighted a similar script (Chapter Thirty-four of the AutoHotkey Applications e-book) which provided most of the same window information. WindowProbe is the same script with a few modifications. Once loaded, WindowProbe.ahk adds a tooltip window to the mouse cursor. As the mouse moves around the screen, the tooltip window displays information from the window and pane just under the cursor: the unique window ID, the window title, the window class, the control name, and the active control name. With the exception of the active control, all the other values change as the cursor moves from window to window. The active control since it is the active field or pane in the active window only changes when a new control is clicked.

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

Title: WindowProbe.ahk - Notepad

Class: ahk_class Notepad

Control: Edit1

Active Control: Edit1

Copy and paste the bits that you need into your script.

The primary additions to the original script are the GetControlFocus command to determine the active control, the hotkey combination to toggle the tooltip window on and off (CTRL++T), and the hotkey combination to save the information to the Windows Clipboard (CTRL+F12). Of particular interest is the toggling technique which can be used to turn virtually anything in an AutoHotkey script on or off. Even though it's not really a beginner's trick, it's worth exploring.

Toggling On and Off

Often there are times when you want to turn a feature on or off without exiting the app. In this case leaving the tooltip in the WindowProbe app turned on can get pretty annoying. The tooltip window (which blinks every ½ second) relentlessly follows the mouse cursor around the screen like a tag-along little brother. It can drive you crazy. This is a job for the toggle.

A toggle is code that switches state every time it runs. It could be from on to off, true to false, or 0 to 1 and vice versa. This is a common programming problem with a variety of solutions. Often, a value is set to 0 for off or false and 1 for on or true, then flipped every time the control state changes. In this case AutoHotkey operators are used to toggle the value of a variable which happens to be called Toggle. (It could be any other variable name.):

SetTimer, WatchCursor, % (Toggle:=!Toggle) ? "Off" : "On"

The exclamation point (!) is the logical NOT. When Toggle (which initially has no value and is therefore false) is set equal (:=) to NOT (!) Toggle, the value of Toggle is flipped from false to true. The next time the code is encountered Toggle will flip from true to false—thereafter, switching again every time the snippet runs.

But there are two other aspects of note in this same line of code. The first is the single percent sign (%) which forces the evaluation of an expression. Adding the force expression sign (%) tells AutoHotkey to evaluate the expression which comes after the % sign—in this case is the ternary operator (?:) (the second item of interest). There are numerous AutoHotkey commands where a forced expression can return a new setting directly to the command.

The ternary conditional operator is a shorthand form of the If-Then-Else statement. It evaluates whatever appears before the question mark (?). If true, it uses the first result after the question mark, but before the colon (:). Otherwise, the ternary returns the result after the colon (:). In the line above, if Toggle evaluates true, SetTimer is set to off. If Toggle evaluates false, SetTimer is set to on. This effectively creates a switch turning the tooltip on or off on each use of the CTRL++T hotkey combination. The power of the ternary conditional operator is that it can be placed directly in many of the AutoHotkey commands to change conditional settings without adding multiple lines of code. (If you're running AutoHotkey basic, you may need to place a space before and after the question mark (?) in the ternary operator.)

The next two lines of code:

If Toggle

ToolTip

merely turn of the tooltip display when Toggle is true (off).

Find the WindowProbe.ahk script and the app WindowProbe.exe (the EXE file runs on any Windows computer without AutoHotkey) at the ComputorEdge AutoHotkey Download site in the WindowProbe.zip file.

For more detailed tips and tricks about AutoHotkey Hotkeys, see the e-book description found in this book by the same name.

Chapter Seven: Quickly Open Favorite Folders

“If you do nothing else, use AutoHotkey to quickly open your most used folders in Windows Explorer.”

This is a cool trick. Do you find that you are opening the same Windows folders innumerable times during the day? Set up a hotkey combination with AutoHotkey to instantly open each of those most used favorites. Plus, you can put those key actions in a quick pop-up menu.

If you have key folders that you're continuously opening in Windows Explorer, then you're going to love this AutoHotkey trick. Rather than open Windows Explorer (+E) and navigate to the right location (or click the folder in your Favorites) every time you need to access an important folder, you can set up a hotkey combination which will instantly open it. All it takes is one line of code. But even better, with only a couple more lines of code, you can add a pop up a menu that does exactly the same thing (see image at left). If you can open Notepad (and have the free AutoHotkey software installed), then in a matter of minutes you can add a cool feature to your Windows computer which will astound your cohorts and friends.

Open Folders Instantly

The first step is to set up a hotkey combination for one of your most used folders. Open Windows Explorer (+E) and navigate to the target folder (see Figure 1). (Windows Explorer is called File Explorer in Windows 8.) Copy the exact path to the folder or use in the AutoHotkey script.

Figure 1. My Dropbox folder is open in File Explorer in Windows 8 (called Windows Explorer in all other versions of Windows).

To copy the folder path, click the little folder icon on the left side of the folder path field (see Figure 2). The field will convert to the proper Windows format and become highlighted for copying. Use the Copy command (CTRL+C) to save the path to the Windows Clipboard.

Figure 2. Click the folder icon on the left side of the path field to highlight the correct syntax for the folder path. Use CTRL+C to copy.

In Windows XP, the folder path will already be in the proper format. Just select and copy. When used in conjunction with the AutoHotkey Run command, this copied path automatically opens the target folder in Windows Explorer.

Once you have installed AutoHotkey, you can right-click in your script folder (or for that matter any folder) and select New => AutoHotkey Script (see image at left). A new AutoHotkey file will be created with the AHK extension. Give it any name you like—possibly, OpenFolders.ahk.

Tip: When the AutoHotkey software is installed on your Windows computer, it adds a number of options to your Windows Explorer right-click context menu. In addition to the New => AutoHotkey Script option mentioned above, whenever you right-click on an AutoHotkey script file name (AHK extension) options for Run Script, Compile Script, and Edit Script are displayed. These options make it much easier to work with scripts. Editing, testing, and compiling are always just one right-click away.

Right-click on the new AutoHotkey script filename and select Edit Script. Your default text editor will open the file for editing. (In many cases, the default text editor will be Notepad. If another editor or word processor opens, be sure that you always save the file as text with the AHK extension.) Add the following line of code to the file:

!2:: Run, C:\Users\Jack\Dropbox

where you substitute your copied path for C:\Users\Jack\Dropbox. (Type Run, then use CTRL+V to paste the new folder path.) Save the file, then right-click and select Run Script which loads the script into memory. That's all there is to it!

Now, every time you use the hotkey combination ALT+2, the target folder will open (or activate if it's already open).

There are certain characters that represent activating hotkeys in AutoHotkey. In this example, the exclamation point (!) represents the ALT key. For CTRL use ^ and for the key use #. These key symbols can be found in the AutoHotkey online documentation for Hotkeys. When these characters (or a combination of them) are used with another key, it creates a hotkey which activates when they are pressed simultaneously.

The AutoHotkey Run command can be used to open folders, open Web pages with your default Web browser, or load programs.

Add a new line of code with a new hotkey combination for each folder:

!1:: Run, C:\Users\Jack\AutoHotkey

!2:: Run, C:\Users\Jack\Dropbox

!3:: Run, \\JACKSLAPTOP\editorial

These lines add two more folders with new hotkey combinations (ALT+1 and ALT+3). Note that the third option is accessing a shared folder on my laptop computer through the network.

If all you want are hotkeys that open your most used folders, then, after adding a line of code for each folder, you can stop right here. But if you have trouble remember the hotkeys, or just want to get a little fancier, then you can add all the hotkeys to a pop-up menu.

Open Folders with a Pop-up Menu

There are only a couple of lines of code required to turn your hotkeys into a pop-up menu. First the Menu command is used to add an option to a menu called Folders:

Menu, Folders, Add, Dropbox,!2

The menu will display Dropbox as the item name and the now familiar !2 (ALT+2) is the hotkey action that clicking the menu item will activate. To display the menu, another hotkey combination is created:

!x::Menu, Folders, Show

which uses the Menu command to Show the menu called Folders. The combination !x (ALT+X) was used because the keys are close together on the keyboard for easy access.

Add another line of code for each menu item:

Menu, Folders, Add, AutoHotkey,!1

Menu, Folders, Add, Dropbox,!2

Menu, Folders, Add, Editorial,!3

Save the file and Reload the script. (Right-click on the AutoHotkey icon in the System Tray and select Reload This Script.) Now whenever you use ALT+X, the menu will pop up at the mouse cursor's location (see image at left). Select the folder you want to open.

If this script does what you want, stop here! But what if you don't want to use the mouse at all?

Adding Hotkeys to the Menu

Adding a hotkey to the menu is merely a matter of putting an ampersand (&) in front of the letter you want to use as the activating key. Here is the entire script with the menu hotkeys added:

Menu, Folders, Add, &AutoHotkey,!1

Menu, Folders, Add, &Dropbox,!2

Menu, Folders, Add, &Editorial,!3

!1:: Run, C:\Users\Jack\AutoHotkey

!2:: Run, C:\Users\Jack\Dropbox

!3:: Run, \\JACKSLAPTOP\editorial

!x::Menu, Folders, Show

When the ALT+X menu is opened, the letter "a" now activates AutoHotkey, the letter "d" activates Dropbox, and the letter "e" activates Editorial. No mouse is needed. The menu will show those letters underlined, as shown at left.

Important note: While the hotkey combination lines of code (!1, !2, !3, and !x followed by the double colon ::) can appear in any order, the three Menu, Folders, Add lines must appear first in the script before any of the double colon lines. These Menu lines need to load immediately. If any of the hotkey setup lines are encountered before the Menu, …, Add lines, the Menu, …, Add lines will not load.

If this is enough, stop here! But, what if you want to only use the mouse without any hotkeys?

Adding the Menu to the System Tray Right-Click Menu

If you prefer to do everything with clicks of the mouse, then with minor modifications you can add the menu to the right-click menu of the System Tray icon. Then all you need to do is right-click on the running AutoHotkey icon, then left-clicking on the target menu item (see image at left).

The only required change to the script is replacing all occurrences of Folders with the word Tray. Then the menu will be added to the bottom of the System Tray AutoHotkey icon right-click menu. All of the hotkey combinations will continue to work, but now you will be able to do it all with only the mouse.

Note: If you do activate the menu with ALT+X (menu pops up next to the mouse cursor, not in the System Tray), since it is using the same letter as a menu hotkey, the standard menu item "Edit This Script" will interfere with selecting the Editorial folder by pressing the "e" key. You may want to switch the menu hotkey to a non-interfering letter such as Edi&torial (activates the letter "t" as a menu hotkey.)

Here is the new script with all the pertinent changes:

Menu, Tray, Add, &AutoHotkey,!1

Menu, Tray, Add, &Dropbox,!2

Menu, Tray, Add, Edi&torial,!3

!1:: Run, G:\Users\Jack\AutoHotkey

!2:: Run, C:\Users\Jack\Dropbox

!3:: Run, \\JACKSLAPTOP\editorial

!x::Menu, Tray, Show

If you don't mind all the extra menu items from the standard System Tray right-click menu, stop here! However, the main problem with the script now is that it's too busy with all of the standard items.

Shortening the Menu

There are a couple of ways to approach removing items from the System Tray menu, but you want to be careful. If you add the line:

Menu, Tray, NoStandard

all the extra items will be removed, but you will also have no way to stop the script (Exit) other than using Windows Task Manager to end the process or modifying the script and reloading it from Windows Explorer. You should at least add Exit back to the menu (shown at left) using a label (subroutine) to exit the app:

Menu, Tray, NoStandard

Menu, Tray, Add, E&xit,Exit

Menu, Tray, Add, &AutoHotkey,!1

Menu, Tray, Add, &Dropbox,!2

Menu, Tray, Add, &Editorial,!3

!1:: Run, G:\Users\Jack\AutoHotkey

!2:: Run, C:\Users\Jack\Dropbox

!3:: Run, \\JACKSLAPTOP\editorial

!x::Menu, Tray, Show

Exit:

ExitApp

Return

The Exit menu item calls the label Exit: which issues the ExitApp command and closes the program.

This last script is not particularly long. It can be easily modified to open Web pages and run programs by adding a new hotkey combination code lines using the Run command and another Menu, …, Add code line to match each new operation hotkey. While there is so much more that AutoHotkey can do, you don't need to go any further than the first step in this column. But finding a quicker way to open your most used folders is something that you really should do.

Third Edition Note: For a more extensive personal menu structure, see the QuickLinks.ahk script for speeding up your usual activities,

Chapter Eight: Using Extra Mouse Buttons and the Wasted Insert Key

“If you do nothing else, use AutoHotkey to power extra mouse buttons and vestigial keys like insert.”

Tips on how use AutoHotkey to take advantage of extra mouse buttons, and the annoying Insert and CapsLock keys.

For me a mouse is just a mouse. I use it to move the cursor around the screen, left-click to select, and right-click for the context menu. On most of my computers I had a standard three-button mouse: left button, right button, and the clickable scroll wheel in the center. That's all I really needed…at least until I started working with AutoHotkey.

On my Windows 8 (now Windows 10) computer, I have a five-button mouse. I didn't plan this. The mouse came with the extra buttons. I've always looked upon the two extra mouse buttons (one on the left side and one on the right) as benign extras like your navel or appendix. However, I would occasionally hit the fourth button on the left side with my thumb accidentally causing a Web page to jump Back. What the heck?

If I hadn't realize what just happened, I could have lost whatever I had been working on. (Tip: If you're working on a Blog and you accidentally go Back or Forward, you can most likely reverse the process and get to your unsaved typing by doing the antithetical (opposite) operation. Right-click and select either Forward or Back as appropriate. If you accidentally close the window (F4), I'm afraid you're out of luck.) I decided it was time to disable these annoying extra mouse button features by putting them to good use with AutoHotkey. (I know that I could have used the mouse drivers that came with the keyboard mouse set, but I find the AutoHotkey solution more flexible.)

Make Use of Extra Buttons on Your Mouse with AutoHotkey

One of the great things about AutoHotkey is that you can make better use of extra mouse buttons and normally (or nearly) useless keys such as the Insert and CapsLock keys. I decided to make use of the fourth mouse button on the left side which has easy thumb access. (If you're left-handed, then the fifth button would have easy thumb access.) It's a bit more natural than trying to use the fifth button on the right side with one of my other fingers. My goal was to eliminate the need to use any hotkey combination when activating the pop-up menu for my QuickLinks AutoHotkey app, (see Figure 1). (The QuickLinks script is discussed in the e-book Digging Deeper Into AutoHotkey.)

Figure 1. Using the extra mouse button gives me an alternative way to open QuickLinks without using the hotkeys.

In my personal combined AutoHotkey script which loads automatically on bootup, I have two hotkey combinations that activate the QuickLinks menu: +Z on the left side of the keyboard and ALT+, (hold down the ALT key and press the comma) on the right side. I wanted to write a one-line script that would activate the QuickLinks menu with a click of that extra fourth mouse button. I thought that I could use either hotkey, but I ended up using the ALT, combination because whenever I tried to use the key, it just wouldn't work properly. I'm not sure why. (There are so many key combinations in Windows 8 and 10 that it's probably best to avoid using in AutoHotkey hotkeys anyway.) All I needed was one line of code to make it work:

XButton1::SendInput, !,

The term for the fourth button is XButton1 with XButton2 designating the fifth mouse button. If you have more than five mouse buttons, then you will need to consult the AutoHotkey documentation's Special Keys section on the KeyList page to uncover how to reach them for reassignment.

If I'm adding the capability directly to the QuickLinks script, then I can put the Menu command for popping up the menu directly into the script:

XButton1::Menu, QuickLinks, Show

For good measure, I assigned opening the main ComputorEdge Web page to the fifth mouse button:

XButton2::Run, http://www.computoredge.com

Now when I click the extra button on the right side, the ComputorEdge Web site opens in the default browser. Note that you can use this technique to activate any AutoHotkey command. If you want to run a longer routine, start the code on the next line after the XButton2:: and enclose it with a Return on the last line.

Making Better Use of the Insert and CapsLock Keys

Most people have no use for the Insert key. The only time it's noticed is when it is accidentally pressed causing volumes of characters to be inadvertently overwritten. Very annoying! This can be prevented by putting the key to good use with AutoHotkey. In the example here, the Insert key is turned into a hotkey which opens the Documents folder in Windows Explorer (File Explorer for Windows 8 users):

Insert::Run, %A_MyDocuments%

Add that one line to the end of any AutoHotkey script (or run it in a standalone script) and you're done. Now whenever you press the Insert key, Windows Explorer will open located at your Documents folder. If you want it to be a different folder, substitute the full folder path including the drive letter (e.g. C:\) for %A_MyDocuments%.

Suppose you want the CapsLock key to open the Command Prompt:

CapsLock::Run, cmd

or the Windows Calculator::

CapsLock::Run, calc

The only problem with this approach is that the CapsLock key is unavailable for when you really need it. To resolve this occasional problem add another line of code with a modifier, such as the Shift key, and the CapsLock key:

+CapsLock::Capslock

Now when you use SHIFT+CAPSLOCK, capitalization will toggle on and off. It's there when you need it, but won't accidentally turn on caps when you inadvertently hit it. However, that slip on the CapsLock key will still activate your AutoHotkey command.

There are a huge variety of things that you can do with extra buttons or unneeded keys, but if all you want to do is disable a button or key, merely add one line similar to this:

XButton1::

You will never accidentally go Back again by hitting that fourth mouse button with your thumb.

For more detailed tips and tricks about AutoHotkey Hotkeys, see the e-book description found in this book by the same name.

Chapter Nine: A Beginner's Guide to Stealing AutoHotkey Apps, Plus Writing and Running Scripts

“There are hundreds of free AutoHotkey apps available for the taking.”

You don't need to know very much about AutoHotkey to take advantage of the many free scripts available for a wide variety of uses on your Windows computer. Here's how to do it. Plus, four scripts you may want to add to your bag of Windows tricks.

There are literally hundreds (if not thousands) of AutoHotkey scripts available for Windows computers. Their purpose and range are diverse and go far beyond those listed on the ComputorEdge AutoHotkey Apps Web page. A plethora of scripts can be found at the AutoHotkey Script Showcase and the AutoHotkey Scripts forum, plus a Web search returns many other pages loaded with AutoHotkey apps. The best thing about all of these scripts is that as long as they offer the source code, you can steal them.

The beauty of using these freely available AutoHotkey scripts is that you don't need to know very much (if anything) about AutoHotkey to use them. You can generally copy them into a new file and run them without alteration. In fact, many people (including myself) use all or part of these listings to build their own apps. You may not understand exactly how the script does what it does, yet you can still do minor tailoring to suit your purposes—especially assigning hotkey combinations which may work better for you.

In the vast majority of cases it's not really stealing. The people who have written these apps are offering them free. Otherwise, they wouldn't post the source code (text files with the .ahk extension) which can be compiled by anyone to run on any Windows computer. In fact, I prefer to get the source code since I then know what I'm compiling. Even I'm concerned about running any EXE file without knowing the source—which is why every AutoHotkey executable file on the ComputorEdge AutoHotkey Free Scripts page has been compiled by me.

If you want to access the multitude of free AutoHotkey apps available, then there are a few steps you need to take to open up this world of Windows tools and utilities. That's why I've put together this "Beginner's Guide To Stealing AutoHotkey Apps."

Install AutoHotkey

The first step is to install AutoHotkey on one of your Windows computers. This will give you all the tools you need to turn AutoHotkey scripts into running apps. You only need the main AutoHotkey program installed on one computer since once you have an AHK source file, you can compile it into an EXE file which will run on any Windows computer without any additional installation.

For AutoHotkey download and installation instructions see "Installing AutoHotkey and Writing Your First Script."

Stealing an AutoHotkey Script

Once you have AutoHotkey installed you're ready to start adding apps to your Windows computer. Search the pages and forums mentioned above looking for the apps that suit you. Most will give a short description of each app and a code listing either in plain text or as an AutoHotkey script file with the .ahk extension (e.g. GooglePhraseFix.ahk). An AutoHotkey script file is simply a text file with a listing of code. Since all the code is in plain text and readable, it is safe to copy the code or download the file. Even if someone tried to add something sinister to an AutoHotkey script, it would not be processed until you ran it as an AutoHotkey or compiled file. Merely downloading a script file is safe enough.

Note: While it is possible for someone to add AutoHotkey code to a script that might mess with your computer (e.g. the RegWrite command or the RegDelete command could be used to alter your Windows Registry), it's highly unlikely that any scripts found on one of the AutoHotkey sites will contain any such issues. They have been downloaded and the code has been reviewed by numerous people who are well versed in AutoHotkey. The site moderators would take down malevolent scripts spotted. In any case, make a quick scan of the code. If you see any commands that look a little unusual in the code listing, investigate it on the Web. That's what I do when I modify and compile the scripts I copy from other sources. I wish that I could say that all the AutoHotkey scripts are 100% safe, but the truth is that AutoHotkey is a powerful language which in the wrong hands could do some damage. That's why, unless you get your code from a trusted source, it's best to learn how AutoHotkey works for yourself and validate all your own scripts.

You will want to create a separate folder to hold all of your AutoHotkey scripts. When you have opened that folder in Windows Explorer (+E), you will then be able to create a new AHK script by right-clicking on an empty space and selecting New => AutoHotkey Script—which has been added to the context menu by the AutoHotkey installation. This creates an AHK file with some boilerplate included. (Boilerplate is default text added to every new AHK file when create through the context menu.) Once you have the new file with the .ahk extension, you will find additional right-click options for the filename: Run Script, Compile Script, and Edit Script (see Figure 1). These options are all you need to turn your AutoHotkey scripts into running apps.

Figure 1. AutoHotkey adds three additional options to the right-click context menu for AHK files: Run Script, Compile Script, and Edit Script.

Edit Script

I recommend that you assign a name to any newly created AHK file which denotes what it does. Then, open the file with a right-click on the file name selecting Edit Script. The file will open in the default text editor—usually Notepad. This is where you paste (place cursor below the boilerplate in the new file, then CTRL+V) the lines of code copied (select all the lines of code and CTRL+C) from the target app at the AutoHotkey script site—CTRL+S to save the file.

Run Script

Once the new script is saved, running it is as simple as right-clicking on the AHK file name in Windows Explorer and selecting Run Script. A little green icon containing the letter "H" will appear in the System Tray and display the file name when the mouse cursor hovers over it. (Some scripts may change the look of the System Tray icon and its Tooltip label.)

You should now be able to test the new AutoHotkey app. After you run it through its paces, you normally will be able to end it by right-clicking on the System Tray icon and selecting Exit. (Worse case, when the option has been deactivated by the script, open Windows Task Manager (CTRL+SHIFT+ESC) to end the running AutoHotkey process.)

Compile Scripts

Once you know that the app is running the way you want it to run, you can compile it into an executable file (EXE) which will run on any of your (or your friends') Windows computers. The great thing about compiling AHK script files into this type of command file is that it makes them completely portable. You can copy the file to any Windows computer (or keep it on a thumb drive) and run it with a simple double-click—no installation required.

You have stolen the app! Want to automatically load it when you log into your computer?

Run Stolen AutoHotkey Apps at Startup

If you like an app, then you probably want to launch it automatically every time the computer boots up. You do this by adding a shortcut to the EXE file (or AHK file if AutoHotkey is installed on the computer) in the Windows Startup folder. This is a two step process. First, create a shortcut from the target app file (see Figure 2 right-click context menu => Create shortcut). Open the Startup folder (+R, enter shell:startup, OK) and drag the new shortcut from the AutoHotkey folder to the Startup folder.

Figure 2. For automatic startup, create a shortcut by right-clicking on the primary file name, open the Startup folder, then drag the shortcut into the Startup folder.

All done! Now every time you log into your computer the new AutoHotkey app will load. If you like the way things are with your new stolen apps, then there is no need to read any further. But, if you want to make a few alterations that might work better for you, then continue on.

Simple Script Tailoring for Personal Use

Maybe everything about your new app will be exactly the way you like it, but usually there is a little tweaking to do—even if it's just to change the hotkey combination(s). Since you're already staring at the code in Notepad, it's usually pretty simple to make minor adjustments, then Save them (CTRL+S). As examples of how to make these types of adjustments to AutoHotkey scripts, I use these apps GooglePhraseFix, HideWindow, WindowRollup, and QuickPrompt—all of which I stole from an AutoHotkey forum. (These scripts are also available at the ComputorEdge Download site.)

Finding and Changing the Hotkey

Hotkeys are distinguished by a double colon (::) appearing after what is usually a combination of at least two characters which often include one or more of ^, !, #, or +. The entire snippets may be all on one line, but usually it consists of a number of lines of code concluded with the Return command. When the entire script consists of one hotkey combination (as is the case with the GooglePhraseFix.ahk app in Figure 3), the hotkey combination can be change by editing the code before the double-colon. The CTRL key is "^", the ALT key is "!", the WIN key () is "#", and the SHIFT key is the "+" character. See Hotkeys for more information and other options. I changed the hotkey combination from ^!C to ^!G (for Google) because I use the letter "C" in too many other hotkey combinations.

Figure 3. The entire app is one hotkey combination starting with ^!g:: (CTRL+ALT+G) and concluding with the "Return" command. Change the characters before the double-colon to change the hotkeys. This type of enclosed hotkey snippet can be added to the end of any other script without adjustment to combine the two scripts.

One advantage to a script such the one above is that it is completely self-contained in one hotkey block. That means you can add the app to any other script by placing the entire code at the end of the other script's file. Actually, you can place it almost anywhere in the file except in the auto-execute section at the beginning which runs on load—as long as it doesn't break up another block of code (hotkey, hotstring, subroutine, or function).

In the HideWindow.ahk script from AutoHotkey Scripts the hotkey combination is saved in a variable:

; This is the hotkey used to hide the active window:

mwt_Hotkey = #h  ; Win+H

; This is the hotkey used to unhide the last hidden window:

mwt_UnHotkey = #u  ; Win+U

Without the comments it would be more difficult to know where to change the hotkey combinations in this script. (Any line or partial line preceded with a semicolon (;) is ignored by AutoHotkey—a comment line.) Hotkeys may also be preceded by the Hotkey command—which is the second most likely place to find and make changes to hotkey combinations.

Adding Scripts to Other Scripts

A while back I wrote a column about "How an AutoHotkey Script Is Processed." Knowing how this works is especially important when combining scripts. If a script includes an auto-execute section (even if it only contains one or two commands) it must appear appropriately in the auto-execute section at the beginning of the final combined script.

For example, in the WindowRollup.ahk script from the AutoHotkey Scripts site there is a one line OnExit command in the auto-execute section which calls the subroutine ExitSub (see Figure 4). This line must appear in the new combined scripts auto-execute section (without the return). The subroutine (ExitSub:) can be placed at the end of the file. However, since many scripts also use OnExit subroutines, it may be necessary to check for conflicts and combine the subroutines.

Figure 4. The OnExit command calls the ExitSub routine to unhide all the previously hidden windows before exiting. If there is more than one OnExit command then the subroutines must be combined in some manner—possibly one calling the other before exiting.

In this app I changed the hotkey combination from +Z to CTRL+Z with the following line:

^z::  ; Change this line to pick a different hotkey.

However, CTRL+Z is the almost universal Undo command, so I should probably look for something else.

More Auto-Execute

In the QuickPrompt.ahk script found in the AutoHotkey forum there are two Hotkey command lines in the auto-execute section (see Figure 5). These two lines need to be placed in the auto-execute section of the combined script whereas the following hotkey (~/) and the Prompt: subroutine can be placed elsewhere in the script as long as they don't break up any other code blocks.

Figure 5. The two Hotkey lines in the beginning of this script should appear in the auto-execute section of a combined script. The other blocks (~/:: through to Return and Prompt: through to Return) can appear anywhere in the script after the auto-execute section at the beginning of the file.

The purpose of the two Hotkey commands is to set up then turn off the ENTER hotkey which calls the Prompt: subroutine. Then Hotkey, Enter can be turned on and off as needed—which is only when the cursor sits in the Windows Explorer address field.

The tilde (~) tells AutoHotkey to pass through the slash (/) to whichever program is active. This prevents AutoHotkey from overriding other uses of the slash character outside of the conditions for this app in Windows Explorer. In this case ~/ is more than just a hotkey combination. If you change this hotkey, then you would need to make other adjustments in the script.

These are just a few hints for any beginner who wants to abscond with AutoHotkey scripts and make them truly their own. The following are more detailed explanations of how these favorite scripts work.

*                    *                    *

Four AutoHotkey Apps Worth Stealing

From time to time I come across AutoHotkey Windows apps which offer new features which enhance the computing experience. Many of these I add to my own bag of trick. I've found a few AutoHotkey apps that are worth introducing to the 90% to readers. These apps are all free and available for download at the ComputorEdge download site. While these are all written in AutoHotkey, you do not need AutoHotkey installed (or even know anything about AutoHotkey) to use them. They have all been compiled into executable command files (.exe extension) and, once extracted from the ZIP file, run with a simple double-click on the filename.

I didn't write these apps myself. I borrowed (or legally stole) the source code from other people who are smarter than me and as explained above made minor changes (mostly to change the hotkey combinations for my own purposes). The truth is that there are portions of each of these scripts that I didn't completely decipher. Although I could see that the code was completely safe, some of the techniques used were in areas of AutoHotkey I have yet to investigate. (Each of these scripts was found at the AutoHotkey Web site and has been reviewed by people with far more expertise than me.) The most important factor is that these apps work.

Since I compiled each of these scripts myself into EXE files for running on any Windows computer, I can personally guarantee that running the programs found on the ComputorEdge download site is safe.

I've already added a couple of these apps to my master tools file for loading on boot up and am considering including the rest.

Google Spelling and Grammar AutoCorrect

When doing a Google search, it's amazing how often it will return the results for "Did you mean?" rather than the typo filled garbage I typed in. It is usually right. An AutoHotkey forum member with the handle aaston86 decided to use this more-often-than-not correct information as a spell checker and whipped together a short "Autocorrect Anything" app which does just that. This cool little app uses Google search to correct selected phrases by accessing the "Showing results for/Did you mean:" line in a Google search results page.

When I started testing it, I quickly found that it did much more than just fixing spelling errors. It was also a reasonable grammar checker. For example, if I type the following line, highlighted it, then hit the hotkeys (I use CTRL+ALT+G):

If your going to you're house

it replaced the text with:

If you're going to your house

Since my dyslexic fingers often confuse "your" and "you're", this is a boon to my writing efforts. I also tested:

to much

two soon

to slow

and to fast

yielding:

too much

too soon

too slow

and to fast

Mostly right, but I was going to fast today anyway. Obviously, there is no way that everything can be caught. There are just too many ambiguities in the English language.

While there are numerous spelling checkers available, this app, which I call GooglePhraseFix, is oriented toward checking groups of words. It seems best at finding typos since if every word is spelled and used correctly it tends to come up empty. Plus, you occasionally may need to run it more than once. For example, the first time:

th quck brwn fx jmped over the lzy dg:

becomes:

the quick brown fox jumped over the lzy dg

The second time through, it was fixed:

the quick brown fox jumped over the lazy dog

Another possible use is for programmers. For example, I noticed that it could correct AutoHotkey syntax:

WinActvte

is recognized as

WinActivate

and

WnGetTtle

becomes

WInGetTItle

Note that in this case when a missing letter is added after a capital letter it's capitalized. It's a quirk of this search on Google. In fact the accuracy of this app is totally dependent upon how Google sees things. If you highlight more than one paragraph, Google will script out all of the carriage returns and make it one long line. Also, depending on the context of the error, it may be completely missed because of another possible usage.

This Google phrase fix app is certainly not a cure all for grammar and spelling problems, but there are many situations where it will help out—especially if you're cleaning up something someone else wrote. I changed the activation hotkey combination and added a line of code to convert apostrophes properly. You can download the app GooglePhraseFix.exe and the AutoHotkey script GooglePhraseFix.ahk in the file GooglePhraseFix.zip from the ComputorEdge download site.

Hide a Window So No One Knows It Exists

Most people have seen apps that either put up a fake work screen or quickly minimize your current active window. Nobody likes people looking over their shoulder while they are using a computer—especially if it's their boss and they're playing a game or wasting time on Facebook. The problem with those fake screen apps is that the real running window can still be found when the fake screen is removed. Or, the active task icon continues to show up in the Windows Taskbar. Anyone with even a little knowledge of Windows will know that something's going on. This HideWindow app makes a window disappear and even removes the active Taskbar icon making it almost impossible to find the hidden window—unless someone knows where to look.

Other than not getting caught goofing off, there are more reasons to use this hidden window app. It declutters the Desktop as well as the Taskbar by removing running windows. In essence, HideWindow takes any active process and moves it into the background. It won't interfere with other programs, nor is anyone likely to accidentally stop it. (This could be useful for programs such as BitTorrent engaged in long downloads.)

For an example of how it works, the Desktop in Figure 1 is covered with various open windows. We could minimize each window and use the Taskbar to restore each one when needed.

Figure 1. Numerous windows are open on the desktop. Three of them (not pinned) show up on the Taskbar.

However, by hitting WIN+H (+H) each active window disappears from the screen. It is not minimized, but hidden. If not pinned to the Taskbar, it will no longer appear in the Taskbar. If the program is pinned to the Taskbar (Windows 7 and 8 only), it will appear as if there is no instance of the program running—no window thumbnail when hovering over it. If you click the pinned icon, a new instance of the program will be opened in a new window. The hidden window will not appear, although it is still running in background. (The exact behavior depends upon the version of Windows running.)

The last hidden window can be revealed with the WIN+U (+U) hotkey combination. Use +U again and the next hidden window pops up. (The hotkey combinations can be changed to your preference in the AHK script file as previously explained. To restore specific windows, right-click on the AutoHotkey icon in the System Tray (green icon with white "H" that's labeled HideWindow (.exe or .ahk) when the cursor hovers over it), then select an individual hidden window from the list or Unhide All Hidden Windows (see Figure 2).

Figure 2. As the windows are hidden (WIN+H) they disappear, are removed from Taskbar (or, if pinned, show as inactive with no thumbnail), and added to the right-click menu for the AutoHotkey icon in the notification area. The three items circled in red (not pinned to Taskbar) no longer appear on the Taskbar. Select a specific window to reactivate it or Unhide All.

This is a pretty old app with the last changes posted on the AutoHotkey site in 2005, but it works well in all versions of Windows. The original source is posted at the AutoHotkey scripts page ("Minimize To Tray Menu"). I've copied it to the HideWindow.ahk and compiled it into the executable (for running on any Windows computer with a double-click) HideWindow.exe. Both can be downloaded from the ComputorEdge download site in the ZIP file HideWindow.zip.

Rollup Windows for More Breathing Space

This next app is designed to semi-minimize active windows when there are numerous windows open 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 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 (see Figure 3). (I changed the hotkey for the original +Z because I was using +Z for my QuickLinks menu app (reviewed in the Digging Deeper Into AutoHotkey e-book). I discuss how to make this change in the hotkeys above. I note in that column 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 steps in this week's AutoHotkey column.)

Figure 3. When the window is active CTRL+Z rolls up the window until only the title bar remains. Toggle CTRL+Z to unroll.

The net effect of rolling up multiple windows is quick, unhidden access to semi-minimized title bars on the Desktop (see Figure 4). This is great for times you need to jump between windows, but don't want to lose view of them behind other windows.

Figure 4. With windows rolled up, many more can be displayed on the same Windows Desktop.

The app called "Window Shading" was written by Rajak and the source is available through the AutoHotkey Scripts Showcase site. I call it WindowRollup and have compiled it into WindowRollup.exe for running on any Windows computer. The command file (EXE) and the source (WindowRollup.ahk) are contained in the WindowRollup.zip file available at the ComputorEdge download site.

Quick Command Prompt

If you need to access the command prompt (see Figure 6) on a regular basis, then you might want to add it to Windows Explorer (File Explorer in Windows 8). This next app which I call QuickPromp adds the Command Prompt capability directly to the folder/file path field (address bar) in Windows Explorer (see Figure 5). 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 (/) as shown in Figure 5.

Figure 5. Click the icon on the left side of the path field (address bar) in Windows Vista, 7, or 8 (not required in Windows XP) in Windows (File) Explorer. Enter one slash (/)or enter two slashes (//), then hit RETURN to run commands or open the Command Prompt set to that folder respectively.

Once the app is loaded (double-click on downloaded and extracted QuickPrompt.exe file), open the Command Prompt at the current location by entering two slashes (//) and hitting RETURN. (In Windows Vista, 7, 8, and 10, first click on the folder icon on the left side of the path field. This gives input access to the field.) The Command Prompt window will open (see Figure 6). However, you don't need to open the Prompt window to run a command.

Figure 6. The Command Prompt can be opened directly from Windows Explorer.

To run Prompt commands from Windows Explorer, enter one slash (/) in the path field followed by the command. For example, to open the calculator enter /start calc. Start is the command for running a program and calc is the name of the Windows calculator program (see Figure 7). The calculator window will open.

Figure 7. Programs can be launched directly from the Command Prompt added to Windows Explorer address field by first entering a slash (/).

There is a fairly long list of the usual utilities and apps you can run. However, you are not limited to running programs. There is also a list of Windows commands available.

I found the source code for QuickPromp.ahk at the AutoHotkey forum. This one was also 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.

Anyone Can Use These Apps

I've highlighted these particular apps because of the hundreds I sifted through, they were both simple and the most universally useful. Anyone can add them to any Windows computer without any knowledge of AutoHotkey. The fact that I think "AutoHotkey is the most powerful free Windows utility software ever" is incidental. You don't need to ever look at AutoHotkey to use these tools. Just download and extract the EXE files and you're ready to go—no installation required! The great thing about free software is it's free!

Chapter Ten: AutoHotkey Versus AutoIt

“Choosing a Windows scripting program for automating your computer activities.”

Both scripting languages are from the same roots, but which one is right for you?

When people begin investigating AutoHotkey, they soon discover that its roots lie in the older Windows scripting language AutoIt. Both programs have active support and serve very similar purposes by adding power to your Windows computer. The question is "Which language is right for you?" Before answering that question the two languages must be compared and contrasted. A Google search will uncover many discussions comparing the two Windows scripting tools, but most of the conclusions come down to people liking what they know best. In this chapter I endeavor to offer enough factual information about both free programs for you to make an informed decision—although the only way to know for sure which is best for you is by testing both..

Full Disclosure: While I attempt to put aside my personal bias (I've written five AutoHotkey books with a sixth on its way) and give a fact-based appraisal grounded upon my research and knowledge of programming languages, I do not have the same in depth knowledge of AutoIt that I do of AutoHotkey. Fortunately, there is a good deal of data for review from people who have used both languages.

First, since both AutoHotkey and AutoIt are free to use, there is no reason not to test or use both. I'm a great believer in using the right tool for the job—especially when the tools are free. If you are comfortable with writing scripts, then you may be served well by playing with each language for particular purposes. There may be applications where one is more suitable than the other. The only cost is the time it takes to do it.

It's important to note that the current versions of the AutoHotkey and AutoIt languages are not interchangeable. Each has its own particular syntax (set of commands and functions) which, while they are capable of accomplishing the same thing, are written in a totally different manner. To make an informed decision you will want to see those differences. A couple of simple examples are provided below.

The Names AutoHotkey and AutoIt

The name of each scripting language gives us insight into the differences between the two. While you can do almost anything in AutoHotkey that you can in AutoIt (and vice versa), there are some noticeable differences. The underlying meaning of the terms AutoIt and AutoHotkey express the original impetus for each program. While both are used for Windows program automation, that is the primary thrust of AutoIt—thus the name. As suggested by the name AutoHotkey, hotkey creation and hotstring replacement through keyboard action is integral to the program. While AutoHotkey has implemented simple ways to create hotkeys and hotstrings, the AutoIt community has never consider those features high priority—although there is a specific function for creating hotkeys in AutoIt—HotKeySet().

It seems that the split occurred after programmer "Chris Mallett's proposal to integrate hotkey support into AutoIt v2" received little response from the AutoIt community causing Mallett to start writing his own version of the then open source AutoIt—calling it AutoHotkey. The name AutoHotkey demonstrates the primary functional difference between the two scripting languages. AutoHotkey offers simple direct support for one-line assignment of hotkeys and hotstrings while the current version of AutoIt requires the use of functions to implement the same or similar hotkey and hotstring features. (See the comparisons below.) This has caused the two language to be viewed very differently. You might say that AutoIt is for Windows automation and AutoHotkey for easy implementation of Windows hotkeys and hotstrings plus Windows automation. (This is not a completely fair comparison since Windows automation, app development, and hotkey/hotstring implementation can be done with either scripting language. They are just done in a different way.)

The result is that many AutoHotkey users who have switched have been extremely pleased with the results after converting most of their scripts to AutoIt, but, even then, they tend to continue using AutoHotkey for their hotkey/hotstring implementations—especially with long list of hotstrings such as the AutoCorrect scripts. Understand that most of these individuals who made the jump to AutoIt from AutoHotkey are more experienced with script writing and programming.

Third Edition Update: After completing a series of blogs on AutoHotkey Hotstrings and Hotkey techniques, I've come to realize that there are many people who might want to use AutoHotkey just for these easy built-in Hotstring and Hotkey structures. If you're a writer, student, or anyone else who does a lot of word processing, then you'll be amazed at the AutoCorrect and text expansion/replacement capabilities of AutoHotkey Hotstrings. For any Windows user, the simple Hotkey format adds automating power to their computer. There are many cool text tricks which you can implement with Hotstrings. This applies equally to the simple built-in basic Hotkey structure in AutoHotkey. The original split between AutoIt and AutoHotkey occurred because of these two easy features. They make it much easier for the beginner to get started with AutoHotkey.

For beginning script writers, the syntax for hotkeys and hotstrings (text expansion) is much simpler in AutoHotkey (a couple of colons ::). This attracts novice users since their first scripts often consists of this type of easy coding. As these beginners become more daring, they naturally venture into the other slightly more complex commands found in AutoHotkey. The function oriented language of AutoIt may be intimidating for the newbie while it might be more natural for the experienced programmer.

The commands in the early versions of AutoIt looked very much like those in the current release of AutoHotkey. After the split between the two languages, AutoIt moved in a new direction (version 3) using more BASIC-like functions while AutoHotkey continued with the original command structure used in the early versions of AutoIt. I don't know that there is a clear advantage of one language structure over the other, but each certainly has its own separate learning curve.

AutoHotkey Versus AutoIt for Hotkeys and Hotstrings

The following is an example of what's required to set up a hotkey in AutoHotkey:

Insert::Run, %A_MyDocuments%

It's one line of code that turns the INSERT (Insert) into a hotkey which opens your Windows Documents folder. The percent signs (%) surrounding the built-in variable A_MyDocuments evaluates the path to the Documents folder.

In AutoIt it takes few more lines:

HotKeySet("{Ins}", "openDocs")

Func openDocs()

Run('explorer ' & @MyDocumentsDir)

EndFunc

The first line uses the AutoIt function HotKeySet() to assign the INSERT key (Ins) to run the user defined function openDocs(). The openDocs() function uses the Run() function to open the Windows Explorer.exe program at the user's documents folder—designated by the macro (built-in variable) @MyDocumentsDir. The ampersand (&) appears to be the symbol for concatenation (combining strings). As can be seen, there are a few more lines needed in AutoIt. This is comfortable for experienced script writers, but could be confusing for the average Windows user.

This next example is a text expansion (or hotstring) for the phrase "by the way" in AutoHotkey:

::btw::by the way

Hotstrings are assigned by placing double colons (::) at the beginning of the line followed by the hotstring and another set of double colons (::btw::). The replacement text (by the way) follows the second set of double colons. Once the script is loaded, anytime "btw" is typed followed by a space or punctuation, it is automatically replaced with "by the way."

I couldn't find a built-in hotstring function in AutoIt, but I did locate this example which includes a special AutoIt script (HotString.au3) to create the function HotStringSet():

#include <HotString.au3>

HotStringSet("callme{enter}", examplefunction)

While 1

Sleep(10)

WEnd

Func examplefunction()

MsgBox(0,"","You typed callme! :)")

EndFunc

To replicate the AutoHotkey example would require the use of the AutoIt Send() function in place of the MsgBox() function. If you need text expansion, then it looks like AutoHotkey may be your program of choice. This is not a minor point since the same simple hotstring technique found in AutoHotkey (in a slightly different format) can be used to run a set of commands in the same manner as a hotkey subroutine.

Both languages are capable of much more involved programming and Windows app building which have nothing to do with either automation or hotkeys/hotstrings. AutoHotkey syntax uses primarily text commands whereas AutoIt uses functions. For example, to add a button to a Graphic User Interface (GUI) window AutoHotkey uses the following command:

Gui, Add, Button [, Options, Text]

To create a Gui button in AutoIt the following function is used:

GUICtrlCreateButton("text",left,top[,width[,height[,style = -1[,exStyle = -1]]]])

This is not a major difference for experienced programmers, but it you've grown accustomed to doing it one way, switching to another method requires developing a different mindset. While there is no particular advantage to the AutoHotkey command structure, it may look simpler to the novice.

The Confusing Side of AutoHotkey

In many ways the current AutoIt version is a much cleaner language than AutoHotkey. It has not fallen victim to the confusion caused by maintaining backward compatibility with older scripts. Since virtually any older AutoHotkey script will run with the current 1.1 version (AutoHotkey_L) of AutoHotkey, there are numerous redundant commands and methods for getting the same thing done. This is a source of confusion for AutoHotkey users because, although there is more than one way to get something done, each requires a different implementation.

The classic example is the use of both the equals sign (=) and a colon plus the equals sign (:=) to assign a value to a variable:

MyString = This is a literal string

CopyOfVar = %Var%

and

MyString := "This is a literal string."

CopyOfVar := Var

are identical sets of expressions. But if you use the wrong one in the wrong place with the wrong format, your script won't run properly. There are a number of other examples of this type of duplication caused by legacy AutoHotkey commands included for backward compatibility. Often the different variations may be used in the same script.

There is an attempt underway to fix the problem and clean up the code with version 2.0 of AutoHotkey. (Version 2.0 is still in the alpha stage of development and not recommended for newbies.) It is designed to eliminate the excess baggage. However, that would mean that many of the scripts available today would no longer run properly with the new version of AutoHotkey. It is difficult to know how widely this new, cleaner version would be accepted. The changes which would be required in older scripts are not well documented and many people will not relish the extra work. As far as I know, AutoIt does not have a similar issue.

Interest in AutoHotkey Versus AutoIt

Based upon links found on Google Trends, interest in AutoHotkey appears to have caught up with AutoIt. (See Figure 1.) This is a momentum which is not likely to reverse.

Figure 1. Interest in AutoHotkey in the United States has slowly caught up with AutoIt. The trend favors AutoHotkey.

The primary reason for the growth of AutoHotkey is its initial simplicity. It's easy for the beginning script writer to get a result with just one line of code in a text file (a hotkey assignment or text string expansion). This is what got me started. Over time, and with a little curiosity, newbies start experimenting with other simple commands and scripts. Eventually, they are hooked and become part of the AutoHotkey community ready to help others.

Since many of the users don't consider themselves to be programmers, the AutoHotkey community works to help each other and is welcoming to beginning users. There are numerous online tutorials and people don't usually face impatiences when they ask newbie questions on a forum. (My experience on the AutoHotkey forums is that at any given time there are usually a number of people online willing and able to answer novice questions.) This makes it easier for people who have never before written a program.

Using AutoIt is a bit more daunting for the newbie script writer. If you're not already a programmer, the concept of using functions can be a little difficult to wrap your brain around. As far as I can see, there is no easy entry point in AutoIt for the complete novice. AutoIt seems to be used more by computing professionals and possibly to a greater degree within corporations. (I have no data to back up this statement, but it was a feeling expressed by AutoIt users.) If I had started with AutoIt first, then, who knows(?), I could be writing AutoIt books. However, I'm not sure the AutoIt users are as likely to need the help. As it is I'm happy with AutoHotkey—even with all of its quirks and idiosyncrasies. It's good stuff.

Some people suggest that AutoHotkey is not as extensive as AutoIt. I would be forced to differ. While there may be some minor technical advantages to AutoIt, I haven't seen much bragged about in AutoIt (arrays, object oriented coding, etc.) which isn't now available in the current version of AutoHotkey 1.1. As far as I can see, both have a great deal of capability for building Windows apps. If more is needed, then possibly the programmers should consider using a programming language such as C++ or Java.

If you're an experienced programmer and the simple hotkey and hotstring assignment found in AutoHotkey is not a requirement in your work, then I would likely recommend AutoIt as your Windows scripting language. If you're a beginner, then AutoHotkey may be just what you need. If you're somewhere in between, then it's a coin toss. Or, maybe you should use both—depending upon what you want to do.

"A Beginner's Guide to AutoHotkey" Contents and Index

“The Table of Contents and Index from the e-book "A Beginner's Guide to AutoHotkey."”

The second edition with more chapters and an index to the AutoHotkey commands found in the book is available in e-book form from the ComputorEdge E-Books Web site (in EPUB, MOBI and PDF formats). 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 offers a gentle approach to learning AutoHotkey.

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.

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 a PDF version for printing on letter size paper for inclusion in a standard notebook of A Beginner's Guide to AutoHotkey click here!

Table of Contents to "A Beginner's Guide"

Chapter One: How to Become a Windows Computer AutoHotkey Superhero

"An Introduction to AutoHotkey features. The best way to keep your job (or get a new one) is make yourself more valuable."

Most small offices have one or two people who have made themselves the in-house IT group. Without the job title, they apply their knowledge to keeping the computers running. Now there is another way to add to superhero status by making it easier to use Windows computers with AutoHotkey.

Chapter Two: Programming Is for Everyone

"Don't think you can program? Think again! Writing software scripts is not just for nerds."

Many people avoid programming because it looks too mysterious and complicated. However, it's really not all that hard. Most people could benefit from writing a little bit of code for their unintelligent computer.

Chapter Three: Installing AutoHotkey and Writing Your First Script

"AutoHotkey, an often overlooked utility program, could become your best friend for your PC."

Some people avoid AutoHotkey because it requires scripting. However, once you understand the possibilities there is plenty of incentive to learn a little coding. Here's how to install AutoHotkey and write your first script.

Chapter Four: More Basic AutoHotkey Techniques

"Changing the case of text from upper to lower and back again."

After introducing the free AutoHotkey utility program in the last chapter, Jack adds a few more techniques which can be used immediately by anyone with a Windows computer.

Chapter Five: Sharing AutoHotkey Scripts

"Compile your AutoHotkey scripts into an executable (EXE) file, plus restoring the original clipboard contents."

There is no need to install the complete AutoHotkey program on every computer. All you need to do is compile your scripts for use on any Windows computer. Plus, how to restore the original Clipboard contents after an AutoHotkey operation.

Chapter Six: Instant Search and Replace

"StringReplace to search and replace any text, anywhere, anytime using Loop and If."

So far we've demonstrated straightforward text substitution and manipulation. Now it's time to do search and replace for multiple items using a Loop and If.

Chapter Seven: Cool Date Tricks with AutoHotkey

"Enter the current date into any Windows program automatically."

AutoHotkey includes tools that make it easy to enter the time and/or date into your documents and files. There is even a cool pop-up calendar for picking alternative dates.

Chapter Eight: Powerful Screen Object Controls in AutoHotkey

"Using the Graphic User Interface (GUI) controls in AutoHotkey to build simple gadgets."

The addition of screen objects to AutoHotkey scripts increases the number of ways that you can use what is "absolutely the best free Windows utility ever." To see the possibilities, peruse the chapter or just look at the pictures.

Chapter Nine: Automatically Resizing Windows with AutoHotkey and User-Defined Functions

"Write a user-defined function for resizing windows to exact dimensions on your desktop."

AutoHotkey includes commands for manipulating the position and size of windows. Including these commands in a user-defined function will add more flexibility to your Windows computing.

Chapter Ten: Make Any Window Always-on-Top Anywhere, Anytime, Plus More "If" Statements

"Using AutoHotkey to make a window always-on-top."

Using AutoHotkey for always-on-top and using "If" conditionals to solve some window size and location problems.

Chapter Eleven: Opening Useful Hidden Windows Folders with AutoHotkey and Making a Help Pop-up

"An easier way to open hidden Windows folders, such as Startup...plus more AutoHotkey and an AutoHotkey help pop-up!"

It can be difficult to find some of the important Windows system folders. Here is the secret to opening them quickly. Then, add this technique to an AutoHotkey script to make it even easier. Also, how to make a pop-up Help window in AutoHotkey.

Chapter Twelve: Cleaning up the Desktop

"A tip for organizing Windows Desktop clutter and more power with AutoHotkey Replace."

Using program icons to quickly recognize new folders used for common file types, plus use AutoHotkey for e-mail addresses and adding "boilerplate."

Chapter Thirteen: Disabling Annoying Windows Hotkeys

"It's easy to Delete All when the Control key is next to the Shift key."

While most Windows hotkey combinations are very useful, there are times when you may want to disable one or two of them. There is a quick and easy way to do that in AutoHotkey.

Chapter Fourteen: AutoHotkey for Copying and Moving Files

"If copying files become tedious with a mouse, it may be time for AutoHotkey."

For copying and moving files, Windows is a point-and-click operating system. Sometimes it's just easier to write a short AutoHotkey script to manipulate file locations.

Chapter Fifteen: How to Cheat at Computer Games and Restarting with AutoHotkey Action Recorders

"AutoHotkey is great for empowering your avatar, plus automatic script creators for beginners."

One of the most popular uses for AutoHotkey is automating computer games. Plus, did you get bogged down with learning AutoHotkey? Actions recorders such as AutoScriptWriter can give you a fresh start.

Chapter Sixteen: Common AutoHotkey Messages and Errors Encountered by the Novice

"Here are a few issues every beginner should understand."

While all AutoHotkey users encounter these warnings and errors at some time, they can cause a great deal of frustration for the beginner. Here is how to deal with them.

Index to "A Beginner's Guide"

$ in front of hotkey combination; Chapter Fifteen

#SingleInstance Off; Chapter Sixteen

#UseHook; Chapter Fifteen

%variable% to return value; Chapter Four

:*: instant auto-replace; Chapter Twelve

:O: option, auto-replace no space; Chapter Twelve

` accent/backtick (special character); Chapter Eleven

`n, special character; Chapter Eleven

`t, special character; Chapter Eleven

= versus := equivalence; Chapter Four

A—Index to "A Beginner's Guide"

A, Active window; Chapter Ten

A_UserName; Chapter Fourteen

Accent/backtick (`); Chapter Eleven

Activating an AutoHotkey Script; Chapter Three

Active window, A; Chapter Ten

Add GUI sub-command; Chapter Eight

Add icon to Windows folder; Chapter Twelve

Adding dates to documents; Chapter One

Adding dates to documents, Notepad (F5); Chapter One

Adding Gui objects; Chapter Eight

Adding the date; Chapter Seven

Adding the time; Chapter Seven

AHK extension; Chapter Three

Always-on-Top; Chapter One, Chapter Eight, Chapter Ten

AutoHotkey (AHK) scripts; Chapter Two

AutoHotkey Dropbox download Web site; Chapter Eight, Chapter Thirteen

AutoHotkey Web Site; Chapter Eleven

AutoHotkey Web Site; Chapter Three

AutoHotkey_L (Current Version); Chapter Three

AutoHotkey_L Web site; Chapter Eleven, Chapter Fourteen

Automatic Loading of AHK Scripts; Chapter Five

Automatic Loading of EXE apps; Chapter Five

Auto-replace, instant (:*:); Chapter Twelve

Auto-replace, no space (:O:); Chapter Twelve

Automating computer games; Chapter Fifteen

AutoScriptWriter; Chapter Fifteen

B—Index to "A Beginner's Guide"

Batch (BAT) files; Chapter Two

Blank spaces, removing; Chapter Three

Blocking annoying windows hotkeys; Chapter Thirteen

Boilerplate, inserting; Chapter Twelve

Buddy control (Gui, Add, UpDown); Chapter Eight

Button GUI; Chapter Eight

ButtonSubmit; Chapter Seven

C—Index to "A Beginner's Guide"

Calculate time and date; Chapter Seven

Calculator, Launch; Chapter Three

Calendar, Pop-up; Chapter One

Calorie Counting app; Chapter Eight

Capitalization; Chapter Four

Cartoon, Hotkeys; Chapter Three

Cartoon, Robots; Chapter Two

Cartoon, Superhero; Chapter One

Centering windows on the screen; Chapter Ten

Character, special, escape sequences; Chapter Eleven

Clipboard contents saving old; Chapter Five

Clipboard, search and replace; Chapter Three

Clipboard, using; Chapter Four

ClipWait command; Chapter Four

Closing a window hides it; Chapter Sixteen

Command Reference; Chapter Fourteen

Commands built into AutoHotkey; Chapter Four

Comments; Chapter Fourteen

Common, errors and messages; Chapter Sixteen

Compile into executable file (EXE), how-to; ChapterThree, Chapter Five

Compiled (EXE) file, AddDate.exe; Chapter Seven

Compiled programs; Chapter Two

Compiler; Chapter Two

Compiling and Sharing AutoHotkey Scripts; Chapter One

Compiling AutoHotkey files; Chapter Thirteen

Computer games automating; Chapter Fifteen

Computer screen size, Program Manager; Chapter Ten

Conditional If statement; Chapter One, Chapter Nine

Conflicting hotkey combinations; Chapter Three

Continue reading next line; Chapter Eleven

Convert .ahk to .exe program; Chapter Five

Convert to lowercase; Chapter Four

Convert to uppercase; Chapter Four

Copying and moving files; Chapter One, Chapter Fourteen

Create a new AutoHotkey script; Chapter Three

Create a new Windows folder; Chapter Twelve, Chapter Fourteen

Create an AutoHotkey (AHK) script file; Chapter Seven

Curly brackets {}; Chapter Nine, Chapter Ten

D—Index to "A Beginner's Guide"

Date calculation; Chapter Seven

Date/Time stamp; Chapter Seven

DateTime GUI; Chapter Eight

Deactivate an AutoHotkey script; Chapter Three

DetectHiddenWindows command; Chapter Sixteen

Differences in AutoHotkey_L; Chapter Three

Dimensions, window,; Chapter Nine

Disable the Windows logo () hotkeys; Chapter Thirteen

Disabling annoying Windows hotkeys; Chapter Thirteen

Disabling or overriding hotkeys; Chapter Thirteen

Distribute scripts to other computers; Chapter Three

Download ComputorEdge AutoHotkey scripts; Chapter Eight

Dropbox folder; Chapter Thirteen

E—Index to "A Beginner's Guide"

Edit GUI control; Chapter Eight

Edit Script; Chapter Seven

E-mail addresses, auto-replace; Chapter Twelve

Error, Variable exists; Chapter Seven, Chapter Sixteen

Error, "Variable cannot be used for more than one control."; Chapter Sixteen

ErrorLevel; Chapter Six

Errors and messages; Chapter Sixteen

Escape sequences; Chapter Eleven

EXE AutoHotkey files; Chapter Thirteen

Executable (EXE) file; Chapter Two, Chapter Five

F—Index to "A Beginner's Guide"

FileCopy; Chapter Fourteen

FileCopyDir; Chapter Fourteen

FileCreateDir; Chapter Fourteen

FileMove; Chapter Fourteen

FileMoveDir; Chapter Fourteen

FileSelectFile; Chapter Fourteen

Files, moving and copying; Chapter One, Chapter Fourteen

Folder, create; Chapter Fourteen

Folder, Windows, Startup, Program Files, and SendTo; Chapter Eleven

Folders, Windows System, Opening; Chapter One

FormatTime command; Chapter Seven

Formatting time; Chapter Seven

Functions, User-Defined; Chapter Nine

G—Index to "A Beginner's Guide"

G-label option; Chapter Eight, Chapter Sixteen

Gaming scripts; Chapter Fifteen

Generating scripts; Chapter Fifteen

Get window title (name); Chapter Fourteen

Global variables; Chapter Seven

Google search code; Chapter Three

Gosub; Chapter Sixteen

Graphic image tools (GUIs); Chapter One

Graphic User Interface (GUI) examples; Chapter Eight

GroupBox GUI; Chapter Eight

GUI (Graphical User Interface) command; Chapter Seven

Gui, +AlwaysOnTop; Chapter Eight

Gui names in combined scripts (eliminating conflicts); Chapter Sixteen

GUI positioning, (ym); Chapter Eight

GUI variables; Chapter Seven

Gui, Add; Chapter Eight

Gui, Add, Checkbox; Chapter Eight

Gui, Add, ComboBox; Chapter Eight

Gui, Add, DateTime; Chapter Eight

Gui, Add, DropDownList; Chapter Eight

Gui, Add, Edit; Chapter Eight

Gui, Add, GroupBox; Chapter Eight

Gui, Add, Hotkey; Chapter Eight

Gui, Add, ListBox; Chapter Eight

Gui, Add, ListView; Chapter Eight

Gui, Add, Picture; Chapter Eight

Gui, Add, Progress; Chapter Eight

Gui, Add, Radio; Chapter Eight

Gui, Add, Slider; Chapter Eight

Gui, Add, Tab; Chapter Eight

Gui, Add, Text; Chapter Eight

Gui, Add, TreeView; Chapter Eight

Gui, Add, UpDown; Chapter Eight

Gui, Destroy command; Chapter Sixteen

Gui, Font; Chapter Eight

Gui, Font, Norm; Chapter Eight

Gui, Show; Chapter Eight

Gui, Submit; Chapter Eight

H—Index to "A Beginner's Guide"

Hidden systems folders, open; Chapter One

Hidden windows, detecting; Chapter Sixteen

Hiding windows; Chapter Sixteen

Hook, keyboard; Chapter Fifteen

Hotkey GUI; Chapter Eight

Hotkeys cartoon; Chapter Three

Hotkeys, Gui objects; Chapter Eight

Hotstring replace "imho" to "in my humble opinion"; Chapter Three

Hotstring replacement (e-mail address); Chapter Two

Hotstring replacement (IMHO); Chapter One

Hotstrings and Auto-replace; Chapter Twelve

Hotstrings options; Chapter Twelve

I—Index to "A Beginner's Guide"

Icon for the AHK file; Chapter Five

Icon for the EXE file; Chapter Five

Icon in the Notification area; Chapter Three

Icon, add to Windows folder; Chapter Twelve

If conditional; Chapter Ten

If statement; Chapter One

If statement in loop; Chapter Six

If statement, conditional; Chapter Nine, Chapter Ten

IfEqual statements; Chapter Ten

IfNotExist; Chapter Fourteen

ImageSearch; Chapter Fifteen

Infinite loop; Chapter Six, Chapter Fifteen

Initial capitalization; Chapter Four

InputVar; Chapter Four

Inserting boilerplate; Chapter Twelve

Installing AutoHotkey; Chapter One, Chapter Three

Instant auto-replace (:*:); Chapter Twelve

Instant Hotkey; Chapter Eight

InstantHotkey app; Chapter Sixteen

Interpreted programs; Chapter Two

Interpreted versus compiled programs; Chapter Two

K—Index to "A Beginner's Guide"

Keyboard hook; Chapter Fifteen

KeyWait command; Chapter Fifteen

L—Index to "A Beginner's Guide"

Label (subroutine); Chapter Seven

Label does not exist error; Chapter Sixteen

Launch Windows Calculator; Chapter Three

Launch Windows Notepad; Chapter Three

Limiting window size; Chapter Ten

Line continuation; Chapter Eleven

ListBox GUI; Chapter Eight

ListView GUI; Chapter Eight

List of hotkeys; Chapter Seven

Load on login, Startup folder; Chapter Five

Loop; Chapter Six

Loop, break; Chapter Six

Lowercase, conversion; Chapter Four

M—Index to "A Beginner's Guide"

Macro recorders; Chapter Fifteen

Making a Help pop-up; Chapter One

Making an EXE file; Chapter Five

Manipulating windows in Windows; Chapter One

Missing label error; Chapter Sixteen

MonthCal GUI (Graphical User Interface); Chapter Seven, Chapter Eight

Morons; Chapter Two

Move a window; Chapter Nine

Moving and copying Windows files in AutoHotkey; Chapter One, Chapter Fourteen

MsgBox command; Chapter Eleven

MsgBox, (Message Box); Chapter One

MsgBox, adding options numbers; Chapter Eleven

MsgBox, Help; Chapter Eleven

N—Index to "A Beginner's Guide"

Naming GUIs in combined scripts; Chapter Sixteen

Next line, continue reading; Chapter Eleven

No space auto-replace (:O:); Chapter Twelve

Notepad, adding the date; Chapter Seven

Notepad, Launch; Chapter Three

Notification area Icon; Chapter Three

O—Index to "A Beginner's Guide"

"Older instance of this script is running" message; Chapter Sixteen

Omission of Gui, Submit; Chapter Seven

Opening hidden Windows systems folders; Chapter One, Chapter Eleven

Organizing for AutoHotkey; Chapter One

OutputVar; Chapter Four

P—Index to "A Beginner's Guide"

Paste the date into any document; Chapter Seven

Pause scripts with Sleep; Chapter Four

Picture GUI; Chapter Eight

PixelSearch; Chapter Fifteen

Pop-up, calendar; Chapter One

Pop-up, Help; Chapter One

Position window; Chapter Nine

Positioning Gui objects; Chapter Eight

Program Files Windows folder; Chapter Eleven

Program Manager, computer screen variable; Chapter Ten

Programming; Chapter Two

Programming, Why learn?; Chapter Two

Progress GUI; Chapter Eight

Pulover's Macro Creator; Chapter Fifteen

R—Index to "A Beginner's Guide"

Recorders, script; Chapter Fifteen

Recorder by Titan; Chapter Fifteen

Regular Expressions (RegEx); Chapter Six

Reload an AutoHotkey script; Chapter Three, Chapter Sixteen

Reload saved script, System Tray icon menu; Chapter Seven

Reload This Script, System Tray icon menu; Chapter Seven

Relocate a window; Chapter Nine

Removing blank spaces; Chapter Three

Replacement, text; Chapter Three; Chapter Fourteen

Resize windows; Chapter One

Return command; Chapter Four

Right-click AutoHotkey menu; Chapter Seven

Robots cartoon; Chapter Two

Run command; Chapter Eight

Run command; Chapter Eleven

Run Script; Chapter Seven

Run www.google.com; Chapter Eight

Running an AutoHotkey Script; Chapter Three

Running AutoHotkey apps on any Windows computer; Chapter Five

RunWait; Chapter Eleven

S—Index to "A Beginner's Guide"

Saving old Clipboard contents; Chapter Five

Screen size variable, Program Manager; Chapter Ten

Screen, centering windows; Chapter Ten

Script, writing your first AutoHotkey; Chapter Three

Script recorders; Chapter Fifteen

Scripting; Chapter Two

Scripts, AutoHotkey (AHK); Chapter Two

Scripts, AutoHotkey Dropbox folder; Chapter Thirteen

Search and replace; Chapter One

Search and replace, text; Chapter Three

Search Google code; Chapter Three

Selecting files; Chapter Fourteen

Selecting hotkey combinations; Chapter Three

Send command; Chapter Seven

Send command; Chapter Four

SendInput; Chapter Fifteen

SendPlay; Chapter Fifteen

SendTo Windows folder; Chapter Eleven

Sharing AutoHotkey Scripts, Compiling; Chapter One

Shell Windows command; Chapter Eleven

Shell: command; Chapter Eleven

Shell:common startup; Chapter Eleven

Shell:ProgramFiles; Chapter Eleven

Shortcuts in Startup, Tip; Chapter Five

Sleep command; Chapter Four

Slider GUI; Chapter Eight

Special character escape sequences; Chapter Eleven

Startup folder for load on login; Chapter Five

Startup folders; Chapter One

Startup folders, two different; Chapter Five

Startup folders, use shortcuts (Tip); Chapter Five

Startup folders, Windows Tip; Chapter Five

Startup Windows folder; Chapter Eleven

StatusBar GUI; Chapter Eight

StringLower; Chapter Four

StringReplace; Chapter Six; Chapter Fourteen

StringUpper; Chapter Four

Submit button; Chapter Seven

Submit, GUI; Chapter Seven

Subroutine (Label); Chapter Seven

Superhero cartoon; Chapter One

Syntax error; Chapter Two

T—Index to "A Beginner's Guide"

Tab GUI; Chapter Eight

"Target label does not exist."; Chapter Sixteen

Text GUI; Chapter Eight

Time calculation; Chapter Seven

Time formatting; Chapter Seven

Title, get window; Chapter Fourteen

To-Do List app; Chapter Eight

TreeView GUI; Chapter Eight

U—Index to "A Beginner's Guide"

UpDown GUI control; Chapter Eight

Uppercase, convert to; Chapter Four

UseErrorLevel; Chapter Six

User-defined Functions; Chapter One, Chapter Nine

User-friendly software; Chapter Two

Using the Windows Clipboard; Chapter Four

V—Index to "A Beginner's Guide"

"Variable cannot be used for more than one control." error; Chapter Sixteen

Variable exists error; Chapter Seven, Chapter Sixteen

Variable, global; Chapter Seven

Variables and Expressions; Chapter Four

W—Index to "A Beginner's Guide"

Wildcards, * and ?; Chapter Fourteen

Window position; Chapter Nine

Window size, limiting; Chapter Ten

Window, always-on-top; Chapter Ten

Window, dimensions; Chapter Nine

Window, move; Chapter Nine

Windows Aero; Chapter One

Windows Explorer icon for the AHK file; Chapter Five

Windows Explorer, right-click AutoHotkey menu; Chapter Seven

Windows folders, Startup, Program Files, and SendTo; Chapter Eleven

Windows System Folders, Opening; Chapter One

Windows Tip for opening Startup folder; Chapter Five

WinGetPos; Chapter Nine, Chapter Ten

WinGetTitle; Chapter Fourteen

WinMaximize; Chapter Nine, Chapter Ten

WinMinimize; Chapter Nine, Chapter Ten

WinMove; Chapter Nine, Chapter Ten

WinRestore; Chapter Ten

WinSet; Chapter Ten

WinShow commands; Chapter Sixteen

Writing Your First Script; Chapter One, Chapter Three

X—Index to "A Beginner's Guide"

XButton; Chapter Fifteen

"Digging Deeper into AutoHotkey" Contents and Index

“The Table of Contents and Index from the e-book "Digging Deeper into AutoHotkey."”

Jack's second AutoHotkey book which is comprised of updated, reorganized and indexed columns from ComputorEdge is now available at ComputorEdge E-Books in EPUB, MOBI and PDF formats. 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.

For a PDF version for printing on letter size paper for inclusion in a standard notebook of Digging Deeper into AutoHotkey click here!

The Table of Contents "Digging Deeper into AutoHotkey"

Introduction to Even More AutoHotkey Script Writing

"AutoHotkey is more than just a few hotkey substitutions."

While there are many simple uses for AutoHotkey, it can be so much more as long as you take the right approach to writing your scripts.

Part I: A Few Quick Tricks in AutoHotkey and Window Spy

"Nine chapters of simple AutoHotkey applications, plus the AutoIt Window Spy utility."

For the novice there are a number of quick app which make AutoHotkey immediately useful. These tips can be used on their own or in other AutoHotkey scripts. Plus, the AutoIt Window Spy utility is introduced for finding mouse click coordinates and identifying windows and controls by name.

Chapter One: Add Currency Symbols and More to Your Keyboard!

"A Windows tip for adding special characters to your editing. . .and then make it quicker with AutoHotkey."

Bring Pennies (¢), British Pounds (£), Euros (€), Degrees (°), Plus or Minus signs (±), and much more to your keyboard with Windows Character Map and single lines of AutoHotkey code.

Chapter Two: Adding Curly Quotes and Brackets to Any Document

"This AutoHotkey trick demonstrates how to surround any text anywhere with anything."

Whether quoting from a Web page or adding parenthetical remarks, AutoHotkey makes it easier to surround the text in a document or edit window.

Chapter Three: Tip for Long E-Mail Addresses

"There is no need to constantly type those long e-mail addresses."

If you have long e-mail addresses then this AutoHotkey tip will make your life easier.

Chapter Four: Always-on-Top Window Tip

"A tip for putting any window always-on-top...and off again."

The one-line AutoHotkey always-on-top script is a must-have for Windows Calculator and Sticky Notes.

Chapter Five: A Tip for Mild Dyslexia, Swapping Letters

"Here's a trick for swapping two mistyped letters."

A quick app for swapping two letters could help those of us who make typos.

Chapter Six: Do a Google Search from Any Program!

"Do a quick Web search!"

This is cool! Here is a short, simple AutoHotkey script that allows you to search the Web from any program or window. Anyone can do it!

Chapter Seven: The Disappearing Taskbar Trick

"Even the Windows Taskbar can be put away with the stroke of a key."

While this trick may not be the most useful, it does give insight into how AutoHotkey works.

Chapter Eight: Make the Insert and Caps Lock Keys Useful and the Missing Windows Key Solution

"Not all keyboards are alike. Here's how to deal with it."

Whether you're an accountant who wants a tab key closer to the number pad or there's no Windows key on your keyboard, AutoHotkey has a solution.

Chapter Nine: A Simple Way to Automate Any Windows Program with (or without) Mouse Movement

"An AutoHotkey script for speeding up any Windows program menu action, plus use a hotkey to simulate mouse movement."

Tired of navigating menus just to do something simple? Automate it in any Windows program with a single line AutoHotkey script. Not only can AutoHotkey automate keystrokes, but it can also simulate mouse movement and clicks.

Chapter Ten: AutoIt Window Spy for Identify Window Names and Coordinates

"Window Spy is possibly the most important utility to use when writing AutoHotkey scripts."

AutoIt Window Spy will give you everything you need to know about the window's inner workings and hidden mechanisms you need to know when writing AutoHotkey scripts.

Part II: The Zen of Writing AutoHotkey Scripts

"AutoHotkey script writing is a process which does not necessarily go in a straight line."

This section of Digging Deeper into AutoHotkey has a two-part purpose. The first is to show new script writers how the process really works. If there are programmers who get it right the first time, I don't know any of them. The second part acquaints you with how AutoHotkey moves, positions and resizes windows, plus a script for finding hidden (off the screen) windows.

Chapter Eleven: The Zen of the Script Writing Process (Part 1): Snapping Windows

"Writing AutoHotkey scripts that work...eventually! Moving, positioning and resizing windows in Windows."

Programming is a process of trial and error. By doing the work one piece at a time, anyone can successfully write a script. In this first part a script for window resizing and moving is studied.

Chapter Twelve: The Zen of the Script Writing Process (Part 2): Snapping Windows

"Writing AutoHotkey Scripts that Work...Eventually!"

Jack continues writing an AutoHotkey script for moving and resizing windows by learning the Windows screen coordinate system and adding the action.

Chapter Thirteen: Finding Lost Windows with AutoHotkey

"The Answer to a Question about Bringing Back a Lost Window with AutoHotkey"

While it may be rare that an open window can't be found, there are ways in AutoHotkey to locate and move all open windows.

Part III: AutoHotkey for Quick Backup of Your Work, Anywhere, Anytime!

"Learn how to create your own backup program while creating and writing text files."

One of the most important Windows tools is one that backs up your current work, even when editing on the Web. In Part III Jack writes an AutoHotkey script that not only saves data but shows you how to create and write text files.

Chapter Fourteen: Protect Against the Pain of Losing Your Computer Work

"A simple AutoHotkey script for temporary backup of new text whether on the Web or working locally."

"Suddenly your computer locks up or the power goes out for a split second. Your heart sinks as you realize that you've lost everything you were working on."

Chapter Fifteen: Incremental Backup to Protect Your Computer Work

"An AutoHotkey System for Saving Changing Versions of Your Files"

Many programs include incremental backup so you can recover earlier versions of your work. Now you can have that protection everywhere instantly with AutoHotkey.

Part IV: Collect Data in One Pot

"This handy AutoHotkey trick for copying from one window to another is a must have for anyone who collects Web information."

Not only will you learn how to quickly collect data, but a free AutoHotkey Scratchpad app by another script writer is introduced as an example of what AutoHotkey can do. It uses an INI file to save setup parameters.

Chapter Sixteen: How to Collect Web Page Text, Web Addresses, and Other Info for Research in One Pot

"With AutoHotkey you can build a tool for collecting data."

This tool for collecting text from Web pages, e-books, documents or any other source is helpful to reporters, students, business people, researchers, or anyone else who needs to work from multiple sources.

Chapter Seventeen: A Free Scratchpad App

"Scratchpad is a simple, quick, free app that makes it easy to take notes."

While you could save notes to an open Notepad window, Scratchpad by Desi Quintans has the advantage of popping up and disappearing quickly at the stroke of a key combination.

Chapter Eighteen: Instant Paste in Scratchpad and Using INI Files

"How to use an AutoHotkey instant paste technique and saving AutoHotkey app values in an INI file."

Copy quotes into Scratchpad without changing windows, plus how to use an INI file to save key parameters and variables in AutoHotkey scripts.

Part V: Quick Launch Links and Menus

"Two different AutoHotkey techniques for adding Start windows and menus to your Windows computer, plus compiling AutoHotkey scripts to EXE files."

See how to use both AutoHotkey GUI windows and the MENU command to create pop-up menus for launching your most used programs and opening favorite Web sites. Plus, adding specialized menus to the System Tray and compiling new icons.

Chapter Nineteen: Make Your Own Start Pop-up for Windows

"Add a new Start window to any version of Windows including Windows 8!"

Missing the Start Menu in Windows 8 or want to do more with any version of Windows? Now you can create your own tailored Start window for any of your Windows computers with AutoHotkey.

Chapter Twenty: A Free QuickLinks Windows App from Jack

"All Your favorite programs, Web sites and documents are only a click away."

Jack offers a simple, easy to use, free app which can replace both the Windows Taskbar and Start Menu links (even in Windows 8). Guaranteed safe. Jack should know. He wrote it.

Chapter Twenty-one: How to Build a Pop-up Menu for Programs, Web Sites and Files

"Reading files from folders to build a menu structure with AutoHotkey."

Jack discusses how his new app QuickLinks was written with a short AutoHotkey script.

Chapter Twenty-two: Tweaking the QuickLinks AutoHotkey Script

"A reader's question prompts a look at improving AutoHotkey scripts by adding QuickLinks to the System Tray icon right-click menu."

What if your keyboard doesn't have a Windows key? Here are some simple modifications to the AutoHotkey scripts. Plus compiling AHK scripts into EXE files that run on any Windows computer.

Part VI: AutoCorrect for All Windows Apps and AutoUpdating AutoHotkey on Multiple Computers

"Add the automatic correction of commonly misspelled words to all of your Windows computers."

AutoCorrect is one of the most valuable AutoHotkey apps. It works across all Windows programs and Web browsers. If you add Dropbox, then you can keep it updated on all of your Windows computers.

Chapter Twenty-three: Add AutoCorrect to Your Windows PC

"For people who fall victim to typos and common misspellings."

Microsoft Word offers AutoCorrect, but now you can add it to all of your other Windows software and Web browsing. You can even add your own personal pet peeves to the list.

Chapter Twenty-four: Adding More to AutoCorrect

"Anyone can add needed keys and other special characters to AutoCorrect."

An AutoHotkey tip for novice script writers to add that needed special character to their techniques for improving AutoCorrect.

Chapter Twenty-five: Updating Programs on Multiple Computers

"A trick for replacing program files on computers with Dropbox."

You are writing and compiling your AutoHotkey scripts on one computer, but using the compiled EXE programs on a number of other Windows computers. Here's how to use Dropbox for a no-hassle way to keep all the connected computers updated.

Part VII: Building the Reminder App Step by Step

"Starting out as a quick same-day reminder, this app slowly gets more robust."

The Reminder app is a quick way to set up a text pop-up cue with an audio reading component. Follow the evolution of this AutoHotkey script.

Chapter Twenty-six: A Cool Little Appointment Reminder for Windows

"Don't forget those scheduled meetings you can't afford to miss!"

AutoHotkey's flexibility is demonstrated with a script which sets up a personal reminder in Windows that breaks through the haze.

Chapter Twenty-seven: Lonely? Make Your Computer Talk to You!

"Add many cool features to your Windows computer with the free NirCmd utility."

NirCmd is a free command line utility which can open and close your DVD trays, hide the clock on the Taskbar, make your computer read to you, and much more.

Chapter Twenty-eight: A Talking Reminder for Windows

"Add the NirCmd Speak command to the AutoHotkey Reminder app."

Now you can make your AutoHotkey Reminder app read your appointment out loud. Plus, there's a better way to calculate time/date differences in AutoHotkey (EnvAdd).

Chapter Twenty-nine: Extending the Reminder AutoHotkey Script Beyond 24 Hours

"Add a calendar and default the date/time GUI to the current time, plus limit the reminder to future dates and time."

Why not a reminder program which schedules for more than the next 24 hours? Plus, default the GUI to the current date and limit your reminders to the future.

Chapter Thirty: Solving More AutoHotkey Reminder Script Issues

"Correcting a time calculation error, check for voice support, disabling the Escape key, and RETURN key problem."

There is another error in the time calculation, plus what happens if there is no voice support. We need to disable the Escape key, and an accidental pressing of the RETURN key dismisses the reminder.

Chapter Thirty-one: Adding Reminder Setup to System Tray Saving the Reminder to a File

"Adding setup to System Tray and how to make the Reminder app last for days with an INI file."

Corrections and enhancement for the Reminder app which teach more valuable AutoHotkey techniques, including adding Reminder setup to the System Tray icon and saving your reminder to disk.

Chapter Thirty-two: Check for Voice, Turn It On and Off, and Change the Cursor

"Is NirCmd installed?; turning voice on and off; and change the cursor to a pointing press finger."

In this wrap up of the current state of the Reminder script, features are added to make the app a little more useable.

Part VIII: Introduction to Databases, Calculating Ages, and Formatting Problems

"A quick app which calculates the age of grandkids uses an INI database and special time calculation function."

While introducing an age calculation function, an INI file is used as a database of grandchildren. The formatting and placement of controls in a GUI object is explained.

Chapter Thirty-three: A GrandKid's Age Calculating App

"Remembering your grandchildren's ages with an INI database."

Here is how to write an app with a simple AutoHotkey database to remember how old your grandkids are.

Chapter Thirty-four: The Age Calculating Function

"A function for dealing with the complications of calculating years, months and days since birth."

For the AutoHotkey obsessed user, the function for age calculation is explained.

Chapter Thirty-five: Text Formatting in GUIs

"Text positioning options in AutoHotkey GUI windows explained."

AutoHotkey has tools for positioning and sizing controls in AutoHotkey windows, but you need to understand how they work.

Index to the E-Book "Digging Deeper into AutoHotkey"

::, hotkey substitution, Chapter Eight, Chapter Twenty-three

:*:, hotkey substitution * option, Chapter Twenty-three

%, expression evaluation with single %, Chapter Thirteen, Chapter Twenty-eight

%, variable value (percent signs %), Chapter Twelve, Chapter Thirteen, Chapter Fifteen

# Commands, Chapter Thirty

#IfWinActive command, Chapter Thirty

#SingleInstance, Chapter Thirty-three

A—Index to "Digging Deeper"

A_Index, Chapter Thirty-three

A_Now (current time), Chapter Fifteen, Chapter Twenty-six, Chapter Twenty-nine

A_LoopFileName, Chapter Twenty-one

A_ThisMenu, Chapter Twenty-one

A_ThisMenuItem, Chapter Twenty-one

A_ThisMenuItemPos, Chapter Twenty-one

A_UserName, Chapter Fourteen, Chapter Fifteen, Chapter Nineteen, Chapter Twenty-one

Active window, Chapter Twelve

Adding a Help window (Scratchpad script), Chapter Seventeen

Adding audio with NirCmd, Chapter Twenty-seven, Chapter Twenty-eight

Adding menu items to System Tray, Chapter Twenty-two

Adding quotes and brackets, Chapter Two

Adding Special Symbols in Windows with Character Map, Chapter One

Adding speech, Chapter Twenty-eight

Adding text together (concatenate), Chapter Five

Adding to an AutoHotkey control, Chapter Eighteen

Age calculation, Chapter Thirty-four

Ahk_class Shell_TrayWnd, Chapter Twelve

Always-on-top, Chapter Four, (Scratchpad script), Chapter Seventeen

Array index (A_Index), Chapter Thirteen, Chapter Thirty-three

Array variable, Chapter Thirteen

Audio, adding with NirCmd, Chapter Twenty-seven, Chapter Twenty-eight

AutoHotkey commands

AutoHotkey key, mouse buttons and joystick list, Chapter Eight

Automating AutoHotkey app launch at startup, Chapter Twenty-three, Chapter Twenty-five

Automating Windows programs, Chapter Nine

AutoCorrect app, Chapter Twenty-three, Chapter Twenty-four

B—Index to "Digging Deeper"

Backup scripts, Chapter Fourteen, Chapter Fifteen

Backup, incremental, Chapter Fifteen

Breaking lines of code, Chapter Nineteen

C—Index to "Digging Deeper"

Calculating, if leap year, Mod(), Chapter Thirty-four

Calculating time, EnvSub, Chapter Twenty-eight

Change button names, Chapter Thirty

Change a keyboard key, Chapter Eight

Change the System Tray icon, Chapter Twenty-two

Character Map, adding special symbols in Windows with, Chapter One, Chapter Twenty-four

Check for program installation, NirCmd, Chapter Thirty

Click command, Chapter Nine, Chapter Fourteen, Chapter Fifteen

Click coordinates, finding, Chapter Ten

Clipboard variable, Chapter Two, Chapter Five, Chapter Fifteen

Comments in scripts (;), Chapter Sixteen

Common misspellings in English, Chapter Twenty-three

Compiling AHK scripts, Chapter Twenty-two

Concatenate operator, Chapter Five

Concatenating (adding) strings (text), Chapter Thirteen, Chapter Thirty-five

Concatenating, self-concatenating operator (.=), Chapter Thirteen

Continue command, Chapter Twenty-one

Continuing lines of code, Chapter Nineteen

Control names, finding, Chapter Ten

ControlSend command, Chapter Sixteen, Chapter Eighteen

ControlSetText, Chapter Thirty

Convert .ahk to .exe utility, Chapter Twenty-two

Coordinate system (x,y), screen and window location, Chapter Twelve

Copy text to another window, Chapter Sixteen

Creating an AHK file, Chapter Fourteen

Critical command, Chapter Fourteen

D—Index to "Digging Deeper"

Database, simple AutoHotkey, Chapter Thirty-three

Date/time specific GUI command, Chapter Twenty-six, Chapter Thirty-one

Date/time, limited range, Chapter Twenty-nine, Chapter Thirty-one

Debugging, MsgBox command for, Chapter Eleven

Disable hotkey combinations temporarily, Chapter Thirty

Disable key in active window, Chapter Thirty

Disabling keyboard keys, Chapter Eight, Chapter Thirty

Disappearing Taskbar Trick, Chapter Seven

Displaying program icons,, Chapter Nineteen

DllCall, Chapter Thirty-two

Dropbox, for updating computers (file sharing), Chapter Twenty-five

Dropdown menu, Chapter Eleven

DropDownList, Chapter Eleven, Chapter Thirteen

E—Index to "Digging Deeper"

E-mail address input, Chapter Three

EnvAdd and EnvSub, difference in time calculation, Chapter Twenty-eight, Chapter Thirty-four

EnvSub command, Chapter Twenty-six, Chapter Twenty-eight, Chapter Thirty, Chapter Thirty-four

Escape character (`) (`), Chapter Fifteen, Chapter Sixteen

EXE, compiling from AHK scripts, Chapter Twenty-two

EXIT, Chapter Twenty-six

Exiting an AutoHotkey app with the System Tray icon, Chapter Twenty-three

F—Index to "Digging Deeper"

FileAppend command, Chapter Fourteen, Chapter Fifteen

FileCreateDir command, Chapter Fifteen, Chapter Twenty-one

FileDelete command, Chapter Fourteen, Chapter Eighteen

Files, hidden and system, Chapter Twenty-one

Finding control and button names, Chapter Ten

Finding window names, Chapter Ten

Folders, looping through files, Chapter Twenty-one

Forcing an expression (%), Chapter Twenty-eight

FormatTime command, Chapter Twenty-six, Chapter Thirty-three

Formatting, GUI, Chapter Eleven, Chapter Nineteen

Formatting options chart, GUI, Chapter Thirty-five

Formatting text, Chapter Thirty-five

Function, HowOld(), Chapter Thirty-three, Chapter Thirty-four

Functions described, what are they?, Chapter Thirty-four

G—Index to "Digging Deeper"

Global variable, Chapter Thirty-four

GoSub command, Chapter Thirty-one

GoSub (Scratchpad script), Chapter Seventeen

GrandKids app, (script), Chapter Thirty-three

GUI (Graphic User Interface) command, Chapter Eleven, Chapter Nineteen, Chapter Twenty-six, Chapter Twenty-nine

GUI, displaying current time and date, Chapter Twenty-nine, Chapter Thirty-one

GUI formatting, Chapter Eleven, Chapter Nineteen

GUI control positioning and sizing options, Chapter Thirty-five

GuiClose:, (window event label), Chapter Twelve

GuiControl command, Chapter Thirteen, Chapter Eighteen, Chapter Twenty-six, Chapter Thirty-two

Gui, Add, Chapter Nineteen, Chapter Twenty-six

Gui, Add, Picture, Chapter Nineteen

Gui, Button control, Chapter Nineteen, Chapter Twenty-six

Gui, Font, Chapter Nineteen, Chapter Twenty-six, Chapter Thirty-two

Gui, Show, Chapter Nineteen, Chapter Twenty-six, Chapter Twenty-six, Chapter Thirty-three

H—Index to "Digging Deeper"

Hotkey command, Chapter Thirty

Hotkey, IfWinActive, Chapter Thirty, Chapter Thirty-one

Hotkeys list, Chapter Sixteen

Hotstrings in AutoHotkey section, Chapter Three

Hotstring substitution options (:*:), Chapter Three

I—Index to "Digging Deeper"

Icons, displaying in AutoHotkey, Chapter Nineteen

IF command, Chapter Twelve, Chapter Thirteen, Chapter Twenty-one, Chapter Twenty-six, Chapter Thirty-two, Chapter Thirty-four

IF statement, one-line, Chapter Thirty-four

IfExist conditional, Chapter Fourteen, Chapter Eighteen, Chapter Thirty, Chapter Thirty-one

IfNotExist command, Chapter Fifteen, Chapter Twenty-one

IfWinActive command (#), Chapter Thirty

IfWin[Not]Exist command, Chapter Sixteen, Chapter Thirty, Chapter Thirty-two

INI file sections, Chapter Thirty-three

INI file keys, Chapter Thirty-three

IniRead, Chapter Eighteen, Chapter Thirty-one, Chapter Thirty-two, Chapter Thirty-three

IniWrite, Chapter Eighteen, Chapter Thirty-one, Chapter Thirty-two, Chapter Thirty-three

IniDelete, Chapter Eighteen

INI files, Chapter Eighteen, Chapter Thirty-three

Installing AutoHotkey, Chapter Twenty-three

Instant paste to Scratchpad, Chapter Eighteen

K—Index to "Digging Deeper"

Keyboard, change a key, Chapter Eight

Keyboard, disabling a key, Chapter Eight

Keyboard, adding a key (), Chapter Eight

L—Index to "Digging Deeper"

Labels, subroutines, Chapter Nineteen, Chapter Twenty-one, Chapter Twenty-six, Chapter Twenty-eight, Chapter Thirty-two

Launching Web sites in a browser, Chapter Nineteen

List open windows (WinGet, OpenWindow, List), Chapter Thirteen

Local variables, Chapter Thirty-four

LOOP (files & folders) command, Chapter Twenty-one, Chapter Thirty-three

LOOP command, Chapter Thirteen

Loop within a loop, Chapter Twenty-one

M—Index to "Digging Deeper"

Menu, add to System Tray, Chapter Twenty-two, Chapter Thirty-one

Menu, disable System Tray item, Chapter Thirty-one

Menu, remove (and add) standard items in System Tray, Chapter Twenty-two

Menu, selection, Chapter Eleven

Menu command, Chapter Twenty, Chapter Twenty-one, Chapter Twenty-two

Mod(), remainder function, Chapter Thirty-four

Modulo, Chapter Thirty-four

Mouse, simulate, Chapter Nine

Mouse click coordinates, finding, Chapter Ten

MouseGetPos, Chapter Twelve

Moving windows, Chapter Eleven

MsgBox, Chapter Thirteen, Chapter Twenty-six, Chapter Twenty-nine, Chapter Thirty

MsgBox command for debugging, Chapter Eleven, Chapter Thirteen

MsgBox Options, Chapter Thirty

N—Index to "Digging Deeper"

NirCmd Windows utility, Chapter Twenty-seven, Chapter Twenty-eight, Chapter Thirty-two

O—Index to "Digging Deeper"

OnMessage() command function, Chapter Thirty-two

Open windows, List (WinGet), Chapter Thirteen

P—Index to "Digging Deeper"

Padding strings, Chapter Thirty-four

Parsing dates, Chapter Thirty-four

Pop-up menu (QuickLinks), Chapter Twenty-one

Program Manager (Windows Desktop), Chapter Twelve

Properties window, Chapter Nineteen

Q—Index to "Digging Deeper"

QuickLinks, add to System Tray, Chapter Twenty-two

QuickLinks AutoHotkey app, Chapter Twenty, Chapter Twenty-one

R—Index to "Digging Deeper"

"Reload This Scrip", Chapter Eleven

Remainder function, Mod(), Chapter Thirty-four

Reminder app, Chapter Twenty-six

Removing special characters (\ and :), Chapter Fifteen

Replacing Windows 8 Start Menu, Chapter Nineteen, Chapter Twenty

Resizing, windows, Chapter Eleven

Return command, Chapter Fifteen, Chapter Nineteen

Run command, Chapter Six, Chapter Sixteen, Chapter Nineteen, Chapter Twenty-eight, Chapter Thirty-two

Run, NirCmd, Chapter Twenty-eight

S—Index to "Digging Deeper"

Saving a file on exit (Scratchpad script), Chapter Seventeen

Saving data, Chapter Eighteen

Scratchpad by Desi Quintans, Chapter Seventeen

Screen and window location system, (coordinates x,y), Chapter Twelve

Search Web, Chapter Six

Section in GUI formatting, Chapter Thirty-five

Selection menu, Chapter Eleven

Send command, Chapter Two, Chapter Six, Chapter Fourteen, Chapter Fifteen, Chapter Eighteen

SetTimer, Chapter Twenty-six, Chapter Twenty-eight, Chapter Thirty

Sleep command, Chapter Fourteen, Chapter Fifteen

Send command, Chapter Sixteen

SendInput, Chapter One, Chapter Five, Chapter Nine, Chapter Twenty-four

Sharing AutoHotkey files with Dropbox, Chapter Twenty-five

Shell_TrayWnd (ahk_class), Chapter Twelve

Sleep command, Chapter Two, Chapter Five, Chapter Six

Special symbols, adding in Windows with AutoHotkey, Chapter One

Fifteen

Start Menu, make your own, Chapter Nineteen

Startup folder, automate AutoHotkey script launch, Chapter Twenty-three, Chapter Twenty-five

Stop a running AutoHotkey app, Chapter Twenty-three

Strings, adding together (concatenate), Chapter Five

StringReplace command, Fifteen

Submenu, Chapter Twenty-one

Submit button, GUI, Chapter Twenty-six, Chapter Twenty-eight

Subroutines, (labels), Chapter Nineteen, Chapter Twenty-one

Substitution (::), AutoHotkey, Chapter Eight, Chapter Twenty-three

SubStr function, Chapter Five, Chapter Thirty-four, Chapter Thirty-five

SubStr, parsing dates, Chapter Thirty-four

SubStr, using to pad characters (left or right)

System Tray, adding right-click menu, Chapter Twenty-two

System Tray, change icon, Chapter Twenty-two

System Tray, removing (and adding) standard menu items, Chapter Twenty-two

System Tray icon, Chapter Eleven

T—Index to "Digging Deeper"

Tabs, (`t), Chapter Thirty-five

Ternary Operator, one-line IF statement, Chapter Thirty-four

Text, adding together (concatenate), Chapter Five

Time, current (A_Now), Chapter Fifteen, Chapter Twenty-six

Time difference calculation, Chapter Twenty-six, Chapter Thirty-four

Time, FormatTime command, Chapter Twenty-six

Time/date specific GUI command, Chapter Twenty-six, Chapter Twenty-nine

Toggle routine, Chapter Twenty-one, Chapter Thirty-two

U—Index to "Digging Deeper"

Understanding formatting GUI controls, Chapter Thirty-five

V—Index to "Digging Deeper"

Variable, array, Chapter Thirteen

Variable value (percent signs %%), Chapter Twelve

Visible, toggling a window (Scratchpad script), Chapter Seventeen

W—Index to "Digging Deeper"

Web search, Chapter Six

Wildcards, Chapter Twenty-one

Window name, finding, Chapter Ten

Window Spy, AutoIt3, Chapter Eighteen, Chapter Ten

Windows, moving, Chapter Eleven, Chapter Twelve, Chapter Thirteen

Windows, resizing, Chapter Eleven, Chapter Twelve

Windows Desktop (Program Manager), Chapter Twelve

WinActivate, Chapter Thirteen, Chapter Sixteen, Chapter Thirty

WinGet command, Chapter Thirteen

WinGetClass, Chapter Thirteen

WinGetPos, Chapter Twelve, Chapter Eighteen

WinGetTitle command, Chapter Twelve, Chapter Fifteen

WinHide, Chapter Seven, Chapter Thirteen

WinMove command, Chapter Twelve, Chapter Thirteen, Chapter Eighteen

WinSet command, Chapter Four

WinShow, Chapter Seven

WinWaitActive, Chapter Sixteen

"AutoHotkey Applications" Contents and Index

“The Table of Contents and Index from the e-book "AutoHotkey Applications."”

Jack's third AutoHotkey book is an intermediate level book of ideas and applications based primarily on the AutoHotkey GUI command. It is available at ComputorEdge E-Books in EPUB, MOBI and PDF formats. 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 extension index to the ideas and techniques covered in the back of the book.

For a PDF version for printing on letter size paper for inclusion in a standard notebook of AutoHotkey Applications click here!

The Table of Contents "AutoHotkey Applications"

Introduction to AutoHotkey Apps and Tricks

"More than just a programming book, "AutoHotkey Applications" is for generating ideas."

While there are many techniques for constructing AutoHotkey gadgets with the built-in Graphical User Interfaces (GUIs), the practical applications included in this book show the real power of AutoHotkey while inspiring more possibilities.

Part I: AutoHotkey Applications

"Most of these applications are demonstrations of the AutoHotkey GUI command but there are other useful apps."

One of the best ways to get ideas for how to implement AutoHotkey applications is to look at what other people have done. If the answer isn't here, then perhaps another idea will be sparked.

Chapter One: Guide to ComputorEdge AutoHotkey App Download Dropbox Site

"A list of the apps on the ComputorEdge Script Download Site and what they do!"

It's about time! With over twenty some AutoHotkey scripts posted on the ComputorEdge AutoHotkey Dropbox free download site, it's time to look at what they all do.

Chapter Two: Five Cool Little Windows Apps

"A dictionary, a scratchpad, easy folder switching, a screen magnifier, and easy foreign characters all written in AutoHotkey."

Digging around the Web and the AutoHotkey community, Jack finds a few apps that any Windows user may like.

Chapter Three: ClipJump, the Free Windows Clipboard Manager

"ClipJump clipboard manager has a number of advantages."

Not everyone needs a Clipboard manager, but if you find that you are constantly using copy-and-paste, then ClipJump may be just the ticket for you.

Chapter Four: An AutoHotkey App for Temporary Hotkeys (HotKey GUI Control)

"Set up hotkey text for inserting into documents and Web pages."

Sometimes you just need a quick way to temporarily enter repetitious and/or long text (e-mail addresses, account numbers, etc.) into documents or forms. Here is a free, quick and dirty app that will do the job with no hassle. This script uses the Gui, Add, HotKey control and the HotKey command to create new hotkey combinations.

Chapter Five: A Quick AutoHotkey App for Playing Music (SoundPlay and FileSelectFile)

"Sometimes all you need is a barebones media player."

If you just want to quickly play a few songs in the background on your computer, here is a free, easy way to do it.

Chapter Six: A Multimedia Greeting Card (Progress/Splash Image, ComObjCreate())

"Rearrange AutoHotkey commands to create novel apps."

Ellen combines a graphic file, an audio file, and the computer voice to create this fun multimedia app.

Chapter Seven: The Perfect Soft Boiled Egg (UpDown and Progress Bar GUI Control, SoundBeep)

"The Immersible Egg Timer or a Recipe for a Barebones Windows Countdown Egg Timer"

Jack offers an AutoHotkey app that counts down to zero before setting off three alarms.

Chapter Eight: Slider App for Dimming the Computer Screen (Slider and StatusBar GUI Control)

"A Simple App That Anyone Can Write to Change the Brightness of Their Windows Computer Screen"

There are AutoHotkey functions available to control most aspects of your Windows computer. You don't need to know how they work to use them. Here is a simple AutoHotkey script called ScreenDimmer which uses one of those mysterious AutoHotkey functions.

Chapter Nine: A Daily To-Do List App (ListView GUI Control and Saving a Data File)

"Using the ListView graphic user interface control a quick and dirty to-do list app is built."

One of the most powerful AutoHotkey controls, ListView, is used to make a simple, easy to use To-Do List app. Plus, the data is saved to a simple text file.

Chapter Ten: More To-Do List App (Resizing and Positioning the GUI)

"Tips and tricks for making AutoHotkey windows easier to resize, position and use and save - and ListView editing."

Prompted by a question, Jack makes improvements to the AutoHotkey To-Do List app. The ListView columns read easier, the window is resizable, and the app saves the window's last size and position for later use. Plus, how to edit directly in the first ListView field.

Chapter Eleven: The Address Book App (ListView, Right-Click Menus, CSV Data File, and E-mail)

"A barebones address book app adds columns and inserts formatted addresses in any document and sends e-mails."

Based upon the To-Do List app built with the AutoHotkey ListView, the Address Book app takes us a few steps further with the addition of columns, use of a CSV data file format, text insertion and e-mail organization.

Chapter Twelve: Address Book App with a Formatted Input Screen, Deletion Protection, and More!

"Built on AutoHotkey ListView, the address book app gets a formatted input screen, protection against accidental deletes, and age calculation."

The Address Book app is changed for better editing, backup, and protection against accidental deletions. Some of these tricks apply to any AutoHotkey app. Plus, age calculation is added as a new feature.

Chapter Thirteen: Calorie Counting App (ListView and GroupBox GUI Controls)

"This AutoHotkey Calorie Counting app imports diet information from the Web, shows the use of GroupBox, and filters ListView by a hidden date column."

AutoHotkey is used to write a script which logs daily food intake while calculating and totaling calories. It builds on the previous To Do List and Address Book apps which use the ListView graphic user interface control.

Chapter Fourteen: Fixing the Calorie Count App (Removing Blank Lines)

"Making the Calorie Count import routine compatible with more Web browsers."

The original version of the script only worked with Google Chrome. Here's how to make the Calorie Count app compatible with more Web browsers.

Chapter Fifteen: Build Your Own Special Purpose Calculator for CalorieCount (ListView)

"These simple calorie count techniques show how to do spreadsheet-like calculations with AutoHotkey."

You could use a spreadsheet for repetitive calculations, but wouldn't it be great to have a specialized AutoHotkey pop-up calculator? The Calorie Count app shows you the basics of how to do it.

Chapter Sixteen: Manipulating Data Files in a Variable for CalorieCount (ListView, FileRead)

"Reading a data file into a variable can save time and disk access."

While it is often easy to work directly with a saved data file, reading the same file into a variable may speed up your AutoHotkey apps.

Chapter Seventeen: Building a Recipe Book with TreeView, Part I (ItemID for Tracking Content)

"AutoHotkey script development with TreeView control, plus using a variable to save a variable."

This time Jack starts the process of writing a recipe book app using the AutoHotkey TreeView control. But, rather than just giving code and explanations, Jack reveals his thought process during the script design and code writing. A data tracking technique that uses the value of a new ItemID as a variable is introduced.

Chapter Eighteen: Building a Recipe Book with TreeView, Part II (CSV File Format for Data)

"Loading the RecipeTree from a data file."

Choosing data file structure is one of the most important decisions when designing scripts. Get it wrong and the headaches will be endless.

Chapter Nineteen: Building a Recipe Book with TreeView, Part III (Editing and Saving Data)

"Time to edit and write the RecipeTree data to a CSV file."

The next step in writing the RecipeTree app is editing data in the window and saving it to a CSV file.

Chapter Twenty: Building a Recipe Book with TreeView, Part IV (Moving Branches Up and Down)

"Moving the recipe ingredients up and down in the TreeView list."

Since the recipe ingredients should be in preparation order, we need a way to swap the branches around. Here is a trick for moving ingredients up and down the list.

Chapter Twenty-one: Building a Recipe Book with TreeView, Part V (Adding Right-click Menus)

"Adding menus to the RecipeTree script for inserting and deleting recipes and ingredients."

While there is always more that can be done, including the features for adding and deleting recipes and ingredients finally makes the app fully functional.

Chapter Twenty-two: Building a Recipe Book with TreeView, Part VI: Finishing Up

"Here are a few things to make any AutoHotkey app a little better."

While it's true that a program is never really completed, here are a few things, such as automatic backup, resizing fields with the window, saving the GUI windows size and position, showing the window with a hotkey or tray menu, checking for changes in the data, and saving on exit, which will make your app a little safer and more usable.

Chapter Twenty-three: Build Your Own AutoHotkey App Control Center (ListView with Menus)

"A basic framework for making it easier to work with various AutoHotkey (and other) programs."

If you're seeing System Tray clutter from too many AutoHotkey icons and getting confused, then here is a way to get better control of your apps.

Chapter Twenty-four: AutoHotkey App Control Center: Adding System Icons and More!

"Adding more to the AutoHotkeyControl app, plus there are 306 icons available in one Windows file."

It's not necessary to provide all of the icons for your AutoHotkey apps yourself. Here's where to look and how to use them. Plus, the simplicity of adding more menu options to the AutoHotkeyControl script.

Part II: AutoHotkey Tips and Tricks

"More AutoHotkey tips and tricks which just may answer that niggling question."

Many more miscellaneous beginning to intermediate AutoHotkey tips are offered in no particular order.

Chapter Twenty-Five: Protect Against Windows Hotkeys

"How to block dangerous unwanted Windows hotkeys, plus stripping double returns."

Windows hotkeys that you didn't know existed can cause you to lose data—and you may not even know why! Here's how to eliminate the problem. Plus, a question about how to remove extra carriage returns from text.

Chapter Twenty-six: Working with Hotstrings as Hotkey Commands

"Hotstrings, although similar to hotkeys, give added flexibility to the auto-replacement feature."

It's easy to forget that hotstrings can do more than just add text to documents through auto-replacement. They can also run snippets of AutoHotkey code.

Chapter Twenty-seven: How to Automate Your New E-mail Messages

"Automatically add the name, e-mail address, subject, message and attachments to your new e-mails."

It's easy enough to send an e-mail attachment in Windows, but now you can add all the other information with AutoHotkey. Here are some alternative methods including how to add multiple attachments.

Chapter Twenty-eight: Fixing Broken Word Wraps

"A short script for removing embedded misplaced new line characters."

Carriage returns and line feeds are a problem when they appear in the wrong place causing formatting issues and broken word wrap. Here is an easy AutoHotkey script that fixes the problem.

Chapter Twenty-nine: A Trick to Avoid Memorizing Hotkeys with a Right-Click Menu

"It's often easier to use a right-click menu."

If you use AutoHotkey extensively then it might be difficult to remember all the hotkey combinations. Here is a quick and dirty trick for adding hotkeys to the System Tray AutoHotkey icon right-click menu.

Chapter Thirty: Adding Icons to AutoHotkey Menus (IfInString, Menu,...,Icon)

"Add Icons to any AutoHotkey Menu making it easier to use."

A long list of items in a menu can be enhanced by adding icons to help distinguish each option.

Chapter Thirty-one: Ellen Gets Help Centering Windows (Functions and Curly Brackets)

"Getting help with a useful AutoHotkey technique by understanding functions and code structure."

Even when already on the right track, sometimes all a person needs is a little push in the right direction. It helps to understand the structure of functions and the use of curly brackets.

Chapter Thirty-two: An Easier Way to Get Your Computer to Talk to You (ComObjectCreate)

"The Reminder app talks to you. Here is a less complicated method."

The development of AutoHotkey for the last few years has continued under new guidance. There are many new powerful features in the latest version AutoHotkey_L. Here is one of them.

Chapter Thirty-three: Adding a Help Window to the AutoHotkey Reminder Script (OnMessage)

"The Reminder App gets an improvement by activating the help button."

As work on the Reminder script continues, the nonfunctional Help button is made functional.

Chapter Thirty-four: Pop-up Labels for All Your Programs (ToolTip Command)

"A question about CapsLock and how to add ToolTip labels that magically appear when hovering."

When hovering a mouse over various controls in programs often help windows pop-up. Learn how to make them happen with AutoHotkey. Plus, controlling CapsLock.

Chapter Thirty-five: A Script to Change the Windows Registry (RegRead and RegWrite Command)

"Many people don't realize that AutoHotkey can modify the Windows Registry."

Some changes to software can only be made in the Windows Registry. Here's how to do it with AutoHotkey.

Chapter Thirty-six: Adding Color to ListView Rows (A_GuiEvent)

"While a little more advanced, this AutoHotkey technique controls the font and background colors of ListView rows."

Using AutoHotkey commands and functions such as DllCall(), SendMessage, and OnMessage, an advanced technique for adding color to AutoHotkey ListView rows is used to enhance the To-Do List script.

Part III: Inner Workings and Hidden Mechanisms

"The more you know about how AutoHotkey processes the AHK files, the easier it is to write scripts."

To resolve many common AutoHotkey problems it's necessary to understand how it works.

Chapter Thirty-seven: Combining Apps into One Script

"Too many AutoHotkey apps running? How to combine them into one! Learn how AutoHotkey thinks."

This may be the most important AutoHotkey chapter yet for understanding how to write and debug scripts. How AutoHotkey processes files.

Chapter Thirty-eight: Packaging Files When Compiling (FileInstall Command)

"Creating EXE files that contain all the needed files."

All the files (graphic and audio) are included in the compiled EXE file and extracted on a double-click.

Chapter Thirty-nine: Hiding the System Tray Icon and Running in the Background (NoTrayIcon)

"How to hide the System Tray icon and running a program in the background."

Too many System Tray icons? Hide a few! Plus, AutoHotkey scripts naturally run in the background, but AutoHotkey can also be used to run other programs invisibly.

Chapter Forty: Common AutoHotkey Messages and Errors

"Here are a few issues everyone should understand."

While all AutoHotkey users encounter these warnings and errors at some time, they can cause a great deal of frustration. Here is how to deal with them.

Part IV: AutoHotkey References

"Places to go for more AutoHotkey help."

There is no book that covers everything that you need. Here are many free resource which will help you on you AutoHotkey journey.

Chapter Forty-one: Free Resources for New AutoHotkey Users

"Where to get answers to Your AutoHotkey questions."

Whether new to script writing or a long-time programmer, there are free resources at the AutoHotkey Web sites.

Chapter Forty-two: Restart Learning AutoHotkey with Action Recorders

"Automatic script builders for generating AutoHotkey code."

Did you get bogged down with learning AutoHotkey? Action recorders such as AutoScriptWriter can give you a fresh start.

Index to "AutoHotkey Applications"

"" Double quotes (escape character); Chapter Sixteen

#IfWinActive; Chapter Twenty-five, Chapter Thirty-seven

#IfWinActive, limit hotkeys and action; Chapter Eleven

#IfWinActive, RecipeTree; Chapter Twenty

#Include command; Chapter Thirty-seven

#Include command; Chapter Twenty-five

#NoTrayIcon; Chapter Thirty-seven

#Persistent; Chapter Thirty-four

#SingleInstance command; Chapter Four

#SingleInstance Force; Chapter Forty

#SingleInstance Ignore; Chapter Forty

#SingleInstance Off; Chapter Forty

% forced evaluation of an expression; Chapter Twenty

. Concatenation operator; Chapter Eight

:: double colon in hotstrings; Chapter Twenty-six

:c*: hotstring options; Chapter Twenty-six

`n; Chapter Thirty-four

`n (new line character); Chapter Nine

`n (new line character); Chapter Five

`n soft return; Chapter Twenty-eight

`n, the escaped line feed character; Chapter Fourteen

`r, the escaped carriage return character; Chapter Fourteen

`r`n hard return; Chapter Twenty-eight

`r`n in e-mail attachments; Chapter Twenty-seven

{ and } curly brackets; Chapter Thirty-one

7-Zip, file compression software (7z extension); Chapter Three

A—Index to "AutoHotkey Applications"

A_AppData; Chapter Thirty-Eight

A_EventInfo built-in variable; Chapter Eight, Chapter Ten, Chapter Twenty-three

A_EventInfo, GuiContextMenu, TreeView; Chapter Twenty-one

A_GuiControl; Chapter Nine

A_GuiEvent = ColClick, ListView column header clicked; Chapter Twelve

A_GuiEvent = e; Chapter Ten

A_GuiEvent (ListView); Chapter Twelve, Chapter Thirty-six

A_GuiEvent (TreeView); Chapter Twenty-two

A_GuiHeight and A_GuiWidth; Chapter Ten

A_GuiX; Chapter Nine

A_Index; Chapter Ten, Chapter Eleven

A_Index; Chapter Fifteen

A_Index (Loop variable); Chapter Five

A_LoopField (Loop variable); Chapter Five, Chapter Eighteen

A_LoopFileExt; Chapter Thirty

A_LoopFileName; Chapter Thirty

A_LoopReadLine; Chapter Nine, Chapter Eighteen

A_Now; Chapter Twelve, Chapter Twenty-two

A_ScriptDir; Chapter Thirty-seven

A_ThisMenuItem; Chapter Thirty

A_TickCount; Chapter Seven

A_Windir; Chapter Thirty

Accelerator keys, Windows; Chapter Twenty-seven

Accent app for adding foreign characters; Chapter Two

Accidentally deleting items; Chapter Twelve

Activate the last window, ALT+TAB; Chapter Twenty-nine

Activate the last window, trick; Chapter Twenty-nine

Activate window with a Hotkey or Tray Menu; Chapter Twenty-two

Activated at its last location, window; Chapter Nine

Add GUI name to label name; Chapter Forty

Add icons to the QuickLinks app; Chapter Thirty

Add icons, menus; Chapter Thirty

Add new items to ListView; Chapter Nine

Add right-click menus to the rows; Chapter Nine

Add text to Gui; Chapter Four

Add TreeView branch at the top level; Chapter Twenty

Adding a hidden column to ListView; Chapter Twelve

Adding accents and special characters (Accents.ahk); Chapter One

Adding color to ListView rows; Chapter Thirty-six

Adding columns to ListView; Chapter Eleven

Adding dates (Adate.ahk and AddDave.ahk); Chapter One

Adding dates with a hotstring as a hotkey; Chapter Twenty-six

Adding e-mail attachments; Chapter Twenty-seven

Adding external files to EXE; Chapter Six

Adding GUI controls for data input and editing; Chapter Twelve

Adding help messages, ToolTip; Chapter Thirty-four

Adding help to an AutoHotkey message box (MsgBox); Chapter Thirty-three

Adding images to ListView; Chapter Twenty-three

Adding items to the System Tray right-click menu; Chapter Four

Adding labels (subroutines) to the System Tray right-click menu; Chapter Five

Adding more columns, ListView; Chapter Nine

Adding multiple attachments, e-mail; Chapter Twenty-seven

Adding to a file, FileAppend command; Chapter Nine

Adding ToolTips; Chapter Thirty-four

Address book (AddressBook.ahk); Chapter One

Address Book app (AddressBook.ahk); Chapter Eleven

Age calculation; Chapter Twelve

AHK files; Chapter One

Ahk_class finding with Window Spy; Chapter Twenty-seven

ALT shortcut keys; Chapter Twenty-seven

ALT+TAB to activate the last window; Chapter Twenty-nine

AltSubmit, A_GuiEvent; Chapter Thirty-six

AltSubmit, ErrorLevel, A_GuiEvent; Chapter Thirty-six

AltSubmit, expanded GUI options; Chapter Eight

AltSubmit, TreeView menus; Chapter Twenty-one

AltSubmitTreeView options; Chapter Seventeen

Always_on_Top.ahk; Chapter One

Always-on-top; Chapter Nine

AlwaysOnTop; Chapter Twenty-three

App control panel for multiple scripts; Chapter Twenty-three

Apps key (GuiContextMenu); Chapter Nine

Apps key (SHIFT+F10); Chapter Twenty-one

AppsKey for context menu; Chapter Twenty-seven

Arrays, variable; Chapter Eleven

Audio files, play; Chapter Five

AutoCorrect.ahk; Chapter One

Auto-execute section; Chapter Twenty-five, Chapter Thirty-seven

AutoHdr, ListView auto column sizing; Chapter Ten

AutoHotkey basic version (AutoHotkey Org.ahk); Chapter One

AutoHotkey Contol Center app (AutoHotkeyControl.zip); Chapter One

AutoHotkey documentation; Chapter Forty-one

AutoHotkey Script Showcase; Chapter Two

AutoHotkey Web site; Chapter Forty-one

AutoHotkey_L documentation; Chapter Thirty-two, Chapter Forty-one

AutoHotkey_L Web site; Chapter Forty-one

AutoHotkey_L, versions of; Chapter Forty-one

AutoHotkeyControl.ahk (application control panel); Chapter Three

AutoIt Window Spy; Chapter Twenty-five

AutoScriptWriter; Chapter Forty-two

Autosize all columns, ListView; Chapter Eleven

B—Index to "AutoHotkey Applications"

+background option, TreeView; Chapter Twenty-two

Background, run in; Chapter Thirty-nine

Background, run in, Run Notepad,, Hide; Chapter Thirty-nine

Backing up data; Chapter Twelve

Backup Data File; Chapter Twenty-two

Backup, incremental; Chapter One

BackupText.ahk; Chapter One

Beep sound; Chapter Seven

Blank lines, scripping out; Chapter Fourteen

Blocking CTRL+W and ALT+F4; Chapter Twenty-five

Blocking Windows Hotkeys; Chapter Twenty-five

Break command; Chapter Seven

Break in Loop; Chapter Twenty-five

Break line that's too long; Chapter Eight

Break Loop with ErrorLevel; Chapter Twenty-five

Break loop with UseErrorLevel; Chapter Fourteen

Brightness, set display; Chapter Eight

Buddy control, UpDown, Gui; Chapter Seven

Buddy1 and Buddy2 options, Slider text, GUI windows; Chapter Eight

Built in function, Floor(Number); Chapter Seven

Built in function, Mod(Dividend, Divisor); Chapter Seven

Built in function, Round(Number [, N]); Chapter Seven

Built in math functions; Chapter Seven

Button control; Chapter Seven

C—Index to "AutoHotkey Applications"

Calculating ages; Chapter One, Chapter Twelve

Calculator, special purpose; Chapter Fifteen

Calorie Count app; Chapter Thirteen

Calorie Count Web site; Chapter Thirteen

CalorieCount.ahk; Chapter One, Chapter Thirteen

CapsLock key turns on; Chapter Thirty-four

Carriage return (`r) linefeed (`n) issues; Chapter Sixteen

Carriage return+line feed (`r`n); Chapter Twenty-five

Carriage returns, problems with, and line feeds; Chapter Fourteen

Centering any active window; Chapter Thqirty-one

Change icon…; Chapter Thirty

ChangeCase.ahk; Chapter One

Changes in the data, check for; Chapter Twenty-two

Changing background color; Chapter Twenty-two

Changing Registry, Windows; Chapter Thirty-five

Changing the System Tray icon; Chapter Eight

Character and variable types, checking (integer, number, upper, lower, valid time or date); Chapter Thirteen

Check for changes in the data; Chapter Twenty-two

Check marks, saving to a text file; Chapter Nine

Checkbox checked in ListView; Chapter Thirty-six

Checkbox checked in ListView, (SendMessage, 4140); Chapter Nine

Checked option, ListView; Chapter Nine

Checking character and variable types (integer, number, upper, lower, valid time or date); Chapter Thirteen

Choosing data file structure; Chapter Eighteen

Class or title, window; Chapter Twenty-five

Clipboard manager (ClipJump); Chapter Three

Clipboard viewing utility (clipbrd); Chapter One

Clipboard, save and restore old contents after use; Chapter Twenty-eight

clipbrd.zip; Chapter One

ClipJump Clipboard manager; Chapter Three

ColClick, A_GuiEvent, ListView column header clicked; Chapter Twelve

Color, adding to ListView rows; Chapter Thirty-six

Color, changing background; Chapter Twenty-two

Column widths, ListView; Chapter Ten

Combining apps in a control panel; Chapter Twenty-three

Combining auto-execute sections in scripts; Chapter Thirty-seven

Combining scripts into one; Chapter Thirty-seven

Comma Separated Values (CSV) file format; Chapter Eleven

Comma Separated Values (CSV) files; Chapter Sixteen, Chapter Seventeen, Chapter Eighteen

Command Reference; Chapter Forty-one

Comment character, semicolon; Chapter Twenty-eight;" semicolon comment character Chapter Twenty-eight

Common error messages; Chapter Forty

ComObjCreate; Chapter Thirty-two

ComObjCreate("SAPI.SpVoice").Speak("It's for you!!"); Chapter Six

ComObjCreate("SAPI.SpVoice").Speak("Your eggs are ready!"); Chapter Seven

ComObjCreate("SAPI.SpVoice").Speak(SpeakOutLoud); Chapter Thirty-two

ComObjCreate() function; Chapter Six, Chapter Seven, Chapter Thirty-two

Comparing the contents of separate folders; Chapter Nine

Compiled into executable (EXE) file; Chapter One, Chapter Six

Compiling AutoHotkey scripts; Chapter Thirty-Eight

Component Object Model (ComObj); Chapter Thirty-two

Computer voice, playing; Chapter Six

ComputorEdge AutoHotkey Dropbox download site; Chapter One

Concatenation operations; Chapter Sixteen

Concatenation operator ( . ); Chapter Eight

Conflicting AutoHotkey GUI windows; Chapter Thirty-seven

Continuation, long lines of code; Chapter Eleven

Continue command; Chapter Ten

ControlSetText command; Chapter Thirty-nine

ControlSetText, Button2; Chapter Thirty-three

Copy the entire file into a variable; Chapter Sixteen

Copying data directly from a Web page into a database; Chapter Thirteen

Countdown timer; Chapter Seven

CSV (Comma Separated Values) file; Chapter Nineteen

CSV (Comma Separated Values) file format; Chapter Eleven

Curly brackets, { and }; Chapter Thirty-one

D—Index to "AutoHotkey Applications"

Data base structure, designing; Chapter Eighteen

Data changes, check for; Chapter Twenty-two

Data file structure, choosing; Chapter Eighteen

Data has changed. Please save changes or revert?(To save click button at left.); Chapter Eighteen, Chapter Twenty, Chapter Forty-one

Data input and editing, adding GUI controls; Chapter Twelve

Data, backing up; Chapter Twelve

Date Finding hidden windows; Chapter Thirty-seven

Dates, adding (Adate.ahk and AddDave.ahk); Chapter One

Dates, adding with a hotstring as a hotkey; Chapter Twenty-six

DateTime; Chapter Thirteen

DateTime ChooseNone option; Chapter Twelve

DateTime GUI control; Chapter Twelve, Chapter Thirteen

Default label names; Chapter Thirty-seven

Default name for a label; Chapter Thirty-four

Definitions from the Web (Dictionary.ahk); Chapter Two

Delete file; Chapter Thirty-Eight

Delete files, FileDelete command; Chapter Nine

Delete, right-click on ListView items to; Chapter Nine

Deleting files on exit; Chapter Six

Deleting installed files; Chapter Six

Deleting items accidentally; Chapter Twelve

Deleting items in TreeView; Chapter Twenty-one

Delimiting character; Chapter Twelve

Delimiting the column headers; Chapter Thirteen

Designing data base structure; Chapter Eighteen

Detect clicked column header; Chapter Twelve

DetectHiddenWindows;

DetectHiddenWindows command; Chapter Eight, Chapter Ten, Chapter Thirty-seven, Chapter Thirty-nine, Chapter Forty

Detecting hidden windows; Chapter Forty

Dictionary script; Chapter Thirteen

Dictionary.ahk; Chapter One

Dictionary.com; Chapter Two

Direct editing in the first column field of ListView; Chapter Ten

Disable menu items; Chapter Twenty-three

Disabling annoying Windows hotkeys; Chapter One

Disabling Windows Hotkeys; Chapter Twenty-five

Displaying birthdays; Chapter Twelve

Displaying other data associated with a branch of the tree, TreeView; Chapter Eighteen

DisplaySetBrightness() user-defined function; Chapter Eight

DllCall(); Chapter Thirty-six

Double quote sets (""), escaping the double quote; Chapter Nineteen

Double quotes ("); Chapter Sixteen

E—Index to "AutoHotkey Applications"

Easy Access Folders; Chapter Two

Edit field for input data; Chapter Eleven

Edit Gui control; Chapter Seven

Edit, right-click on ListView items to; Chapter Nine

Editing and data input, adding GUI controls; Chapter Twelve

Editing and saving data; Chapter Twelve

Editing in the first column field of ListView (-readonly option); Chapter Ten

Editing TreeView branches; Chapter Eighteen

Egg timer, soft boiled; Chapter Seven

EggTimer.ahk; Chapter One, Chapter Seven

E-mail attachments, adding; Chapter Twenty-seven

E-mail formatting and initiation (MailTo); Chapter Twenty-seven

E-mail, adding multiple attachments; Chapter Twenty-seven

E-mail, MailTo parameter for Run command; Chapter Eleven

E-mail, send to address book entry; Chapter Eleven

Embedding images and sounds in EXE files (FileInstall); Chapter Six

Enable menu items; Chapter Twenty-three

Error messages, common; Chapter Forty

Error, GUI variable exists; Chapter Thirty-seven

Error, older instance of this script is already running; Chapter Forty

Error: Target label does not exist; Chapter Forty

Error: The same variable cannot be used for more than one control; Chapter Forty

ErrorLevel for Process ID; Chapter Twenty-three

ErrorLevel, A_GuiEvent, AltSubmit; Chapter Thirty-six

ErrorLevel, break Loop with; Chapter Twenty-five

Escaped with the tick mark (`); Chapter Nineteen

Escaping the double quote (""); Chapter Nineteen

Evaluation of an expression, forced (%); Chapter Twenty

EventInfo; Chapter Eleven

Events, double-click, right-click, column-click, and exit editing; Chapter Ten

EXE files; Chapter One

ExitApp command; Chapter Four, Chapter Six, Chapter Thirty-Eight

F—Index to "AutoHotkey Applications"

FavoriteFolders.ahk for opening and saving files; Chapter One, Chapter Two

Fields resize when a window is resized; Chapter Twenty-two

File, create new, FileAppend; Chapter Nine

File, save list to a; Chapter Nine

File, save window size and position on the screen; Chapter Ten

FileAppend command; Chapter Sixteen, Chapter Nine, Chapter Ten, Chapter Nineteen

FileAppend creates new file; Chapter Nine

FileCopy command; Chapter Six, Chapter Nine, Chapter Sixteen, Chapter Nineteen, Chapter Thirty-Eight

FileCopy, AddressBook.txt, AddressBook%A_Now%.txt backup; Chapter Twelve

FileDelete command;

FileDelete, RecipeTree.csv; Chapter Nineteen

FileInstall command for compiling external files; Chapter Six, Chapter Thirty-seven, Chapter Thirty-Eight

FileMove command; Chapter Nineteen, Chapter Twenty-two

FileOpen() function; Chapter Sixteen

FileRead command; Chapter Sixteen

Files from folders, selecting; Chapter Five

FileSelectFile command; Chapter Five

Find a window's ahk_class (Window Spy); Chapter Twenty-seven

Finding available icons; Chapter Twenty-four

Fixing broken word wraps; Chapter Twenty-eight

Floor(Number) built in function; Chapter Seven

Folder contents, listing; Chapter Nine

FolderOpen.ahk; Chapter One

Folders, Quick access to favorites in any program (FavoriteFolders.ahk); Chapter Two

Forced evaluation of an expression (%); Chapter Twenty

Formatted input/editing screen, adding GUI controls; Chapter Twelve

FormatTime command; Chapter Twelve

FormatTime, CurrentDateTime,, MMMM d, yyyy; Chapter Twenty-six

Formatting Gui control layout; Chapter Seven

Formatting, GUI controls; Chapter Twelve

Forum on the AutoHotkey site; Chapter Forty-one

Forum on the latest AutoHotkey site; Chapter Forty-one

Full option, TreeView; Chapter Nineteen

Function, built in, Floor(Number); Chapter Seven

Function, built in, Mod(Dividend, Divisor); Chapter Seven

Function, built in, Round(Number [, N]); Chapter Seven

Functions; Chapter Nine

Functions and code structure; Chapter Thirty-one

Functions; Chapter Five, Chapter Thirty

Functions, built in math; Chapter Seven

G—Index to "AutoHotkey Applications"

G-Label (subroutine); Chapter Fifteen, Chapter Forty

G-Label Notifications (Secondary); Chapter Twenty-one

G-Label Notifications; Chapter Ten

Global; Chapter Twenty-two

Gosub; Chapter Five, Chapter Forty

Goto; Chapter Five

GrandKids 5.ahk; Chapter One

GrandKids.ahk; Chapter One

Grapic image in ListView; Chapter Twenty-three

GroupBox GUI control; Chapter Thirteen

Gui +/-options; Chapter Ten

Gui +AlwaysOnTop; Chapter Eight, Chapter Nine

Gui +OwnDialogs (dialogue ownership); Chapter Thirty-three

Gui +Resize option; Chapter Ten

Gui command; Chapter Seven

GUI commands; Chapter Thirty-two, Chapter Thirty-four

Gui control formatting; Chapter Seven

GUI error, variable exists; Chapter Thirty-seven

Gui formatting; Chapter Twelve

GUI name must be added to the label name; Chapter Forty

GUI names in combined scripts; Chapter Forty

GUI naming system in AutoHotkey_L; Chapter Thirty-seven

Gui options, use of; Chapter Eight

GUI window event label; Chapter Ten

GUI window resizable by dragging; Chapter Ten

GUI window; Chapter Twenty-three

GUI windows, resizable; Chapter Ten

Gui, Add command structure; Chapter Nine

Gui, Add command; Chapter Nine

Gui, Add, Button; Chapter Seven, Chapter Thirty-two

Gui, Add, Button; Chapter Four

Gui, Add, DateTime; Chapter Twelve, Chapter Thirteen

Gui, Add, Edit; Chapter Four, Chapter Twelve, Chapter Fifteen, Chapter Seventeen, Chapter Thirty-two

Gui, Add, Hotkey; Chapter Four

Gui, Add, Progress command; Chapter Seven

Gui, Add, Slider command; Chapter Eight

Gui, Add, StatusBar; Chapter Eight

Gui, Add, Text; Chapter Four, Chapter Twelve

Gui, Add, TreeView command; Chapter Seventeen, Chapter Eighteen, Chapter Nineteen

Gui, Destroy;

Gui, Destroy command; Chapter Thirty-seven, Chapter Forty

Gui, Show; Chapter Four, Chapter Seven, Chapter Thirty-two, Chapter Forty

Gui, Submit command; Chapter Four, Chapter Seven, Chapter Eight, Chapter Fifteen, Chapter Nineteen

Gui, Submit, NoHide; Chapter Seven, Chapter Thirteen, Chapter Thirty-two

GuiClose label; Chapter Twenty-two

GuiContextMenu for creating right-click menus; Chapter Nine, Chapter Eleven, Chapter Twelve, Chapter Twenty-three

GuiContextMenu, TreeView; Chapter Twenty-one

GuiControl command; Chapter Seven, Chapter Nine, Chapter Twenty-two, Chapter Thirty-two

GuiControl to update; Chapter Fifteen

GuiControl, , MyEdit with TreeView; Chapter Seventeen

GuiControl, ,Edit1; Chapter Nine

GuiControl, ,Edit1; Chapter Eleven

GuiControl, ,Food2, %RowData1%; Chapter Thirteen

GuiControl, +backgroundFFFFCC, MyTreeView; Chapter Twenty-two

GuiControl, +ReadOnly, MyEdit; Chapter Nineteen

GuiControl, Move command; Chapter Ten

GuiControl,, Edit1 (updating edit field); Chapter Seven

GuiControl,, MyProgress (updating progress bar); Chapter Seven

GuiSize; Chapter Ten

GuiSize, problem with multiple fields; Chapter Twelve

H—Index to "AutoHotkey Applications"

Hard returns; Chapter Twenty-eight

Help button; Chapter Thirty-three

Help, ToolTip; Chapter Thirty-four

Hidden column sorting in ListView; Chapter Twelve

Hidden column, adding to ListView; Chapter Twelve, Chapter Thirteen

Hidden from view; Chapter Thirteen

Hidden windows; Chapter Thirty-seven

Hide icon, Menu, Tray, NoIcon; Chapter Thirty-nine

Hide the icon in the System Notification Tray; Chapter Thirty-nine

HIde, run in background, Run Notepad,, Hide; Chapter Thirty-nine

Hiding System Tray icon; Chapter Thirty-seven

HotKey command; Chapter Four, Chapter Five, Chapter Twenty-three

Hotkey or hotstring placement in script; Chapter Twenty-five

HotKey parameter (GUI); Chapter Four

Hotkeys, app to set up temporary; Chapter Four

Hotstring as a hotkey; Chapter Twenty-six

Hotstring text; Chapter Twenty-six

Hotstrings as commands; Chapter Twenty-six

HowOld() user-defined age calculating function; Chapter Twelve

I—Index to "AutoHotkey Applications"

Icon in the System Notification Tray, hide; Chapter Thirty-nine

Icon, changing the System Tray; Chapter Eight

Icons file types, ICO, CUR, ANI, EXE, DLL, CPL, SCR; Chapter Thirty

Icons, finding; Chapter Twenty-four

Identify whether a TreeView branch is a parent or a child; Chapter Nineteen

If; Chapter Seven

If conditionals; Chapter Thirteen

If Firstchar = `n; Chapter Fourteen

If rowdata%A_Index% contains Serving Size; Chapter Thirteen

If var is type; Chapter Thirteen

IfEqual command; Chapter Thirty-four

IfExist; Chapter Ten

IfInString commands; Chapter Thirty

IfWinActive; Chapter Five, Chapter Twenty-five, Chapter Thirty-seven

IfWinNotExist; Chapter Thirty-seven, Chapter Forty

IL_Add(ImageListID, "SHELL32.dll",72); Chapter Twenty-four

IL_Create(), image list in ListView; Chapter Twenty-three

IL_Create(4); Chapter Twenty-four

Image list in ListView; Chapter Twenty-three

ImageList.ahk; Chapter One

ImageList.ahk, SHELL32.dll icon numbers app; Chapter Twenty-four

ImageList.exe; Chapter Thirty

Images, adding to ListView; Chapter Twenty-three

ImageSearch; Chapter Forty-two

Importing data directly from a Web page into a database; Chapter Thirteen

Incremental backup; Chapter One

Incremental backup of the data file; Chapter Sixteen

IncrementalSaveText.ahk; Chapter One

Incrementing the progress bar; Chapter Seven

Indent code; Chapter Thirty-one

INI files, using; Chapter Seventeen, Chapter Eighteen

Initiate script on startup; Chapter Six

IniWrite; Chapter Sixteen

Input screen layout of Calorie Count; Chapter Thirteen

Instances of script, multiple, running; Chapter Four

Instant definitions dictionary app; Chapter Two

Instant pop-up window controls; Chapter Eight

InstantHotkey, set up temporary hotkeys; Chapter Four

InStr(); Chapter Sixteen

ItemID, TreeView control; Chapter Seventeen

ItemID, TreeView, storing data in; Chapter Eighteen

J—Index to "AutoHotkey Applications"

JPG and WAV files, including in compiled file; Chapter Six

L—Index to "AutoHotkey Applications"

Label (subroutine); Chapter Forty

Label names, default; Chapter Thirty-four, Chapter Thirty-seven

Labels (subroutines); Chapter Five, Chapter Fifteen

Last active window, SendInput, !{Escape}; Chapter Eleven

LaunchWindow.ahk; Chapter One

Layout of the Calorie Count window; Chapter Thirteen

Limit when hotkey combinations work; Chapter Twenty

Line continuation for too long code lines; Chapter Eight, Chapter Eleven, Chapter Thirty-five

Line continuation, trick to avoid; Chapter Eight

Line feeds, problems with, and carriage returns; Chapter Fourteen

Linking a TreeView branch to an Edit field; Chapter Eighteen

List of Windows Messages (WM_HELP = 0x53); Chapter Thirty-three

List saved to a text file; Chapter Nine

Listing a folder's contents; Chapter Nine

ListView column widths (automatic); Chapter Ten

ListView command; Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen, Chapter Fifteen, Chapter Twenty-three, Chapter Thirty-six

ListView Control (ToDoList.ahk); Chapter One

ListView events, double-click, right-click, column-click, and exit editing; Chapter Ten

ListView IL_Create() function; Chapter Twenty-three

ListView ImageList; Chapter Twenty-four

ListView rows, adding color,; Chapter Thirty-six

ListView Sort option; Chapter Nine

ListView, add new items to; Chapter Nine

ListView, adding more columns; Chapter Nine

ListView, Checkbox checked in, (SendMessage, 4140); Chapter Nine

ListView, Checked option; Chapter Nine

ListView, Column widths; Chapter Ten

ListView, editing in the first column field of; Chapter Ten

ListView, LV_Add() function (add rows); Chapter Nine

ListView, LV_GetCount() function (number of rows); Chapter Nine

ListView, scrollbars; Chapter Ten

ListView. number of rows in (LV_GetCount()); Chapter Fifteen

Load multiple instances of a script; Chapter Forty

Loop;

Loop % LV_GetCount(); Chapter Eleven

Loop command; Chapter Five, Chapter Six, Chapter Seven, Chapter Nine, Chapter Twelve, Chapter Fifteen

Loop, % LV_GetCount(); Chapter Thirty-six

Loop, %Rowdata0%; Chapter Thirteen

Loop, break with ErrorLevel; Chapter Twenty-five

Loop, break with UseErrorLevel; Chapter Fourteen

Loop, Parse command; Chapter Five, Chapter Eleven

Loop, Parse, A_LoopReadLine, CSV; Chapter Eleven

Loop, Read command; Chapter Nine

Loop, Read, AddressBook.txt; Chapter Eleven

Loop, Read, RecipeTree.csv; Chapter Eighteen

Lost windows, finding (WindowList.ahk); Chapter One

LV_Add("Check", CheckedText); Chapter Nine

LV_Add() function, ListView; Chapter Nine, Chapter Eleven, Chapter Fifteen, Chapter Twenty-three

LV_Delete(RowNumber); Chapter Nine

LV_GetCount() function, ListView; Chapter Nine, Chapter Eleven, Chapter Fifteen

LV_GetNext(); Chapter Eleven, Chapter Fifteen

LV_GetNext(RowNumber - 1,"Checked"); Chapter Nine

LV_GetText(); Chapter Eleven

LV_GetText(ColText, A_EventInfo,1); Chapter Twelve

LV_GetText(LastTotalCal,LV_GetCount(),7); Chapter Fifteen

LV_GetText(Text, A_Index) function, ListView; Chapter Nine

LV_Modify() function; Chapter Eleven, Chapter Fifteen, Chapter Twenty-three

LV_Modify(0,"Select"), Select All; Chapter Eleven

LV_Modify(SelectedRow,"",NewItem); Chapter Nine

LV_ModifyCol() function; Chapter Ten, Chapter Twelve

LV_ModifyCol(1,"AutoHdr"); Chapter Twenty-three

LV_ModifyCol(1,"Sort"), sort column; Chapter Eleven

LV_ModifyCol(A_Index,"AutoHdr"); Chapter Eleven

LV_SetImageList() for adding images to ListView; Chapter Twenty-three

LV_SetImageList(ImageListID); Chapter Twenty-four

M—Index to "AutoHotkey Applications"

Macro recorder; Chapter Forty-two

Magnifier, screen; Chapter Two

Magnifier.ahk; Chapter One

MailTo parameter for Run command; Chapter Eleven

Mailto protocol; Chapter Twenty-seven

Media player, AutoHotkey; Chapter Five

Menu command; Chapter Four, Chapter Nine, Chapter Twelve, Chapter Twenty-one, Chapter Twenty-three, Chapter Twenty-four, Chapter Thirty

Menu separator bars; Chapter Thirty-seven

Menu, MenuName, Icon; Chapter Thirty

Menu, MyContextMenu, Add, Insert Address; Chapter Eleven

Menu, Tray command; Chapter Eight

Menu, Tray, Add command; Chapter Four, Chapter Five, Chapter Six

Menu, Tray, Click, 1 to activate with a System Tray icon click; Chapter Eight

Menu, Tray, Icon; Chapter Thirty-nine

Menu, Tray, Icon, Shell32.dll, 44; Chapter Eight

Menu, Tray, NoIcon; Chapter Thirty-seven, Chapter Thirty-nine

Menu, Tray, Tip; Chapter Four

Menus, add icons; Chapter Thirty

Message Box (MsgBox) help button; Chapter Thirty-three

Messages, Windows list; Chapter Thirty-three

Minimized window problem; Chapter Twelve

MinMax option, WinGet command; Chapter Twelve

Mod(Dividend, Divisor), built in function; Chapter Seven

MonthCal control; Chapter Forty

MouseGetPos; Chapter Thirty-four

Moving branches up and down in TreeView; Chapter Twenty

MsgBox command; Chapter Five, Chapter Seven, Chapter Twelve, Chapter Twenty-two, Chapter Thirty-three, Chapter Thirty-five

MsgBox option numbers (adding); Chapter Twelve

MsgBox options; Chapter Thirty-three

MsgBox, viewing parsed data; Chapter Fourteen

Multimedia greeting card or welcome message (PhoneRing.zip); Chapter One

Multimedia Greeting Card with sound and splash image; Chapter Six

Multiple instance of script, running; Chapter Four, Chapter Forty

Music player, (QuikPlay.ahk); Chapter One

Mute.ahk; Chapter One

N—Index to "AutoHotkey Applications"

Names, default label; Chapter Thirty-seven

Naming system, GUIs; Chapter Thirty-seven

NirCmd utility software; Chapter Thirty-two

NoHide option for Gui, Submit; Chapter Eight, Chapter Thirty-two

NoHotkey.ahk; Chapter One

NoSort option, ListView; Chapter Twenty-three

NoTicks option, Slider, GUI windows; Chapter Eight

Number of rows in ListView (LV_GetCount()); Chapter Fifteen

O—Index to "AutoHotkey Applications"

Older instance of this script is already running, error; Chapter Forty

Older version message; Chapter Forty

"Older version" message; Chapter Forty

OnExit command; Chapter Six, Chapter Nine, Chapter Thirty-Eight

OnExit, GuiClose; Chapter Twenty-two

OnMessage function (Windows); Chapter Thirty-three

OnMessage to monitor the Windows WM_HELP message (0x53); Chapter Thirty-three

OnMessage; Chapter Thirty-six

OnMessage() function; Chapter Thirty-four

OnMessage() function (AutoHotkey); Chapter Thirty-four

OnMessage(0x53, "WM_HELP"); Chapter Thirty-three

Open a window for picking files (FileSelectFile); Chapter Five

Opening the default e-mail program; Chapter Eleven

P—Index to "AutoHotkey Applications"

Parse a line of text, StringSplit; Chapter Eleven

Parsing data imported from different Web browsers; Chapter Fourteen

PathCheck.ahk; Chapter One

PhoneRing.ahk (a multimedia message); Chapter Six

PhoneRing.zip; Chapter One

Picking files from folders; Chapter Five

PixelSearch; Chapter Forty-two

Playing audio or video files; Chapter Five

Pop-up window controls; Chapter Eight

Portable file for playing on other Windows computers; Chapter Six

Position and Size, save GUI Window; Chapter Twenty-two

Problems with carriage returns and line feeds; Chapter Fourteen

Process command; Chapter Twenty-three, Chapter Thirty-nine

Process command, is script running?; Chapter Twenty-three

Process command, stop a script; Chapter Twenty-three

Process ID; Chapter Thirty-nine

Process, Close command; Chapter Twenty-three

Program Manager, determine computer screen dimensions; Chapter Nine

Progress bar; Chapter Seven

Progress command; Chapter Six

Protect against accidental deletion, TreeView; Chapter Twenty-one

Protect Edit field from accidental changes, (GuiControl, +ReadOnly, MyEdit); Chapter Nineteen

Pulover's Macro Creator; Chapter Forty-two

Q—Index to "AutoHotkey Applications"

Quick access to favorite folders in any program (FavoriteFolders.ahk); Chapter Two

Quick-start Tutorial; Chapter Forty-one

QuikPlay audio file playing app; Chapter Five

QuikPlay.ahk; Chapter One

R—Index to "AutoHotkey Applications"

Range, Gui option; Chapter Seven

Range60-180; Chapter Eight

Read text out loud; Chapter Thirty-two

Reading a CSV file; Chapter Eleven

Reading a data file; Chapter Nine

Reading a data file into memory (a variable); Chapter Sixteen

Reading voice, ComObjCreate() function; Chapter Six

-ReadOnly; Chapter Nineteen

-readonly option for direct editing; Chapter Ten

Readonly option ListView; Chapter Twenty-three

-ReadOnly option, TreeView; Chapter Eighteen

RecipeTree.ahk; Chapter One

Record key strokes; Chapter Forty-two

Recorder by Titan; Chapter Forty-two

RegEx; Chapter Thirteen

Registry loop command; Chapter Thirty-five

Registry with AutoHotkey; Chapter Thirty-five

Registry, Windows , changing; Chapter Thirty-five

RegRead; Chapter Thirty-five

Regular Expressions (RegEx) (Dictionary.ahk); Chapter Two

RegWrite; Chapter Thirty-five

Reload command; Chapter Eight, Chapter Twenty

Reload This Script; Chapter Forty

Reminder.ahk; Chapter One

Removing blank lines from text; Chapter Fourteen

Removing extra returns; Chapter Twenty-eight

Removing File Extensions from the Menu; Chapter Thirty

Removing installed image and sound files; Chapter Six

Removing line feeds and carriage returns from text; Chapter Fourteen

Resizable GUI windows; Chapter Ten

+Resize option, Gui; Chapter Twenty-three

Resize fields when a window is resized; Chapter Twenty-two

Resize GUI controls with window automatically; Chapter Ten

Resize GUI window by dragging; Chapter Ten

Resize option, Gui +; Chapter Ten

Restore old Clipboard contents after use; Chapter Twenty-eight

Return (`r) linefeed (`n) issues; Chapter Sixteen

Return command; Chapter Four

Return+line feed (`r`n); Chapter Twenty-five

Returns, problems with, and line feeds; Chapter Fourteen

Returns, removing extra; Chapter Twenty-eight

Reverse option, Slider, GUI windows; Chapter Eight

Right-click in a GUI, GuiContextMenu; Chapter Eleven

Right-click menu, different for each ListView row; Chapter Twenty-three

Right-click menu, setting up, ListView; Chapter Nine

Right-click menus, GuiContextMenu for creating; Chapter Nine

Right-click menus, TreeView; Chapter Twenty-one

Right-click on ListView items to edit or delete; Chapter Nine

Round() function; Chapter Fifteen

Round(Number [, N]), built in function; Chapter Seven

Run (+R) to open Startup folder; Chapter Six

Run command; Chapter Eleven, Chapter Twenty-three, Chapter Thirty-nine

Run in the background; Chapter Thirty-nine

Run multiple instances of a script; Chapter Forty

Run Notepad,, Hide; Chapter Thirty-nine

Run script multiple times; Chapter Four

Run, C:\Users\%A_UserName%\QuickLinks\%A_ThisMenu%\%A_ThisMenuItem%; Chapter Thirty

Run, http://caloriecount.about.com for Web search; Chapter Thirteen

Run, mailto; Chapter Twenty-seven

S—Index to "AutoHotkey Applications"

Safety of AutoHotkey AHK files; Chapter One

Save GUI Window Size and Position; Chapter Twenty-two

Save list to a text file; Chapter Nine

Save old Clipboard contents to later restore; Chapter Twenty-eight

Save window size and position on the screen to a the data file; Chapter Ten

SaveText.ahk; Chapter One

Saving check marks to a text file; Chapter Nine

Saving ListView columns to a data file; Chapter Eleven

Saving new paragraphs in a CSV file; Chapter Nineteen

Saving on Exit; Chapter Twenty-two

Saving the Edited Data; Chapter Nineteen

SayWhat.ahk; Chapter One, Chapter Thirty-two

SB_SetIcon("Shell32.dll", 44), StatusBar GUI control function; Chapter Eight

SB_SetParts([Width1, Width2, ... Width255]), StatusBar GUI control function; Chapter Eight

SB_SetText(), StatusBar GUI control; Chapter Eight

Scratchpad; Chapter Two

Screen dimensions, determine with Program Manager; Chapter Nine

Screen magnifier; Chapter Two

ScreenDimmer.ahk; Chapter One, Chapter Eight

Script design; Chapter Seventeen

Script recorders; Chapter Forty-two

Script Summaries; Chapter One

Scripts, combining into one; Chapter Thirty-seven

Scripts, compiling to EXE; Chapter Thirty-Eight

Scrollbars, ListView; Chapter Ten

Search and import feature from Web to save typing; Chapter Thirteen

Search for calories on the Web; Chapter Thirteen

Section option (start a new section), Gui; Chapter Seven

Select All (CTRL+A) in ListView; Chapter Eleven

Selecting multiple media files; Chapter Five

Semicolon (;) comment character; Chapter Twenty-eight; Chapter Twenty-eight

Send address to other documents and programs; Chapter Eleven

Send an e-mail to address book entry; Chapter Eleven

Send command; Chapter Twenty-three

Sending an e-mail; Chapter Eleven

Sending Web page data to Calorie Count app; Chapter Thirteen

SendInput command; Chapter Four

SendInput command, use lowercase hotkey letter with; Chapter Thirty-seven

SendInput, !{Escape}, last active window; Chapter Eleven

SendMessage tutorial; Chapter Thirty-six

SendMessage; Chapter Thirty-six

SendMessage, 4140 (Checkbox checked in ListView); Chapter Nine

SetCapsLockState; Chapter Thirty-four

SetTimer command; Chapter Six, Chapter Thirty-four

Setting up the right-click menu, ListView; Chapter Nine

Shell:startup to open Startup folder; Chapter Six

SHELL32.dll; Chapter Thirty

SHELL32.dll graphic icons; Chapter Twenty-four

Size and position, save GUI Window; Chapter Twenty-two

Size and positional options, GUI windows; Chapter Eight

Sleep command; Chapter Seven, Chapter Twenty-eight

Slider Control (ScreenDimmer.ahk); Chapter One

Slider Gui; Chapter Eight

Soft boiled egg timer; Chapter Seven

Sort command; Chapter Sixteen

Sort option, ListView; Chapter Nine

Sort option, TreeView; Chapter Twenty, Chapter Twenty-one

Sort when updating or editing in ListView; Chapter Eleven

Sorting a hidden column in ListView; Chapter Twelve

Sorting option of ListView; Chapter Eleven

Sorting variable contents; Chapter Sixteen

Sorting, preventing in ListView; Chapter Twenty-three

Sound, beep; Chapter Seven

SoundBeep command; Chapter Seven

SoundPlay command; Chapter Five, Chapter Six

SoundPlay, NoFile.wav; Chapter Thirty-Eight

SoundSet; Chapter One

Speaking voice, ComObjCreate("SAPI.SpVoice").Speak(SpeakOutLoud); Chapter Thirty-two

Speed up apps, reading a file into memory; Chapter Sixteen

SplashImage command; Chapter Six

SplashImage, Off; Chapter Six

Split lines of code; Chapter Thirty-five

Spreadsheet like calculator; Chapter Fifteen

Spy ToolTip; Chapter Thirty-four

Start Menu replacement (Quicklinks.ahk); Chapter One

Start pop-up for Windows, (LaunchWindow.ahk); Chapter One

Startup folder, Run (+R) to open; Chapter Six

StatusBar control acting as a button; Chapter Eight

StatusBar GUI control; Chapter Eight

Sticky Notes; Chapter Nine

Stop a script, Process command; Chapter Twenty-three

Storing data in TreeView ItemID; Chapter Eighteen

StringReplace command; Chapter Thirteen, Chapter Fourteen, Chapter Sixteen, Chapter Twenty-five, Chapter Twenty-seven, Chapter Twenty-eight, Chapter Thirty

StringReplace, clipboard, clipboard; Chapter Twenty-eight

StringReplace, clipboard, clipboard, `r, , all; Chapter Twenty-eight

StringSplit command; Chapter Eleven, Chapter Twelve

StringSplit, RowData, Clipboard , `n,; Chapter Thirteen

StringTrimLeft, CheckedText, A_LoopReadLine, 1; Chapter Nine

Stripping carriage returns and line feeds from text; Chapter Twenty-eight

Stripping out blank lines; Chapter Fourteen

Subroutines (labels); Chapter Five, Chapter Fifteen, Chapter Forty

SubStr() function; Chapter Nine, Chapter Sixteen

SubStr(clipboard,1,1); Chapter Fourteen

System Tray icon, changing; Chapter Eight

System Tray right-click menu; Chapter Four, Chapter Five

System Tray Tooltip; Chapter Four

System Tray, no icon; Chapter Thirty-seven

T—Index to "AutoHotkey Applications"

TAB (1) centers text, TAB (2) right justifies, StatusBar; Chapter Eight

Table format, ListView; Chapter Nine

Target label does not exist, error; Chapter Forty

TickInterval option, Slider, Gui windows; Chapter Eight

Timer, egg, soft boiled; Chapter Seven

Title or class, window; Chapter Twenty-five

To-Do List App; Chapter Nine

ToDoList.ahk; Chapter One, Chapter Nine, Chapter Ten

Toggle example; Chapter Thirty-five

ToolTip; Chapter One

ToolTip command; Chapter Thirty-four

Tooltip option, Slider, GUI windows; Chapter Eight

Tooltip, System Tray; Chapter Four

TreeView branches, editing; Chapter Eighteen

TreeView control (branch ItemID); Chapter Seventeen

TreeView documentation; Chapter Seventeen

TreeView GUI; Chapter Eighteen

TreeView GuiContextMenu: label; Chapter Twenty-one

TreeView ItemID, storing data in; Chapter Eighteen

TreeView options (AltSubmit); Chapter Seventeen

TreeView right-click menus; Chapter Twenty-one

TreeView, displaying data associated with a branch of the tree; Chapter Eighteen

TreeView, linking a branch to an Edit field; Chapter Eighteen

TreeView, moving branches up and down; Chapter Twenty

TreeView, Sort option; Chapter Twenty

Trick to avoid line continuation; Chapter Eight

Trim character, StringTrimLeft, CheckedText, A_LoopReadLine, 1; Chapter Nine

Turning a variable value into a variable (TreeView); Chapter Seventeen

TV_Add("New Recipe",0,"Sort"); Chapter Twenty-one

TV_Add() TreeView function; Chapter Seventeen, Chapter Twenty

TV_Delete(ItemID); Chapter Twenty-one

TV_GetCount() TreeView; Chapter Seventeen

TV_GetNext(); Chapter Twenty

TV_GetNext(ItemID, "Full"); Chapter Nineteen

TV_GetParent() TreeView; Chapter Seventeen

TV_GetParent(A_EventInfo); Chapter Twenty-one

TV_GetParent(ItemID); Chapter Nineteen, Chapter Twenty, Chapter Twenty-one

TV_GetPrev(); Chapter Twenty

TV_GetSelection() TreeView; Chapter Seventeen, Chapter Eighteen, Chapter Nineteen, Chapter Twenty

TV_GetText() TreeView; Chapter Seventeen

TV_GetText(OutputVar, ItemID); Chapter Nineteen

TV_GetText(OutputVariable, ItemID); Chapter Twenty

TV_GetText(TreeText, TV_GetSelection()); Chapter Eighteen

TV_Modify(0, "Sort"); Chapter Twenty

TV_Modify(ItemID, "Select"); Chapter Twenty-one

TV_Modify(NewAdd, "Select"); Chapter Twenty-one

U—Index to "AutoHotkey Applications"

Unique ID number of the window; Chapter Thirty-four

UpdateFile() user-defined function; Chapter Nine

UpDown Gui control; Chapter Seven

Use a lowercase hotkey letter with the SendInput command; Chapter Thirty-seven

UseErrorLevel to break a loop; Chapter Fourteen

UseErrorLevel with Loop; Chapter Twenty-five

User set hotkeys; Chapter Four

Using INI files; Chapter Seventeen, Chapter Eighteen

V—Index to "AutoHotkey Applications"

Variable already exists, error; Chapter Forty

Variable and character types, checking (integer, number, upper, lower, valid time or date); Chapter Thirteen

Variable array; Chapter Eleven

Variable exists error; Chapter Thirty-seven

Versions of AutoHotkey_L; Chapter Forty-one

View the icons in a file; Chapter Thirty

Viewing the available icons; Chapter Twenty-four

Voice, computer, ComObjCreate() function; Chapter Six

Voice, computer, playing; Chapter Six

Voice, speaking, ComObjCreate("SAPI.SpVoice").Speak(SpeakOutLoud); Chapter Thirty-two

Voice, Windows; Chapter Thirty-two

W—Index to "AutoHotkey Applications"

WAV sound file, playing; Chapter Six

Web page, copying data directly from into a database; Chapter Thirteen

Web page, sending data to Calorie Count app; Chapter Thirteen

WinActivate; Chapter Eight, Chapter Thirteen

Window centering, active; Chapter Thirty-one

Window class or title; Chapter Twenty-five

Window Spy; Chapter Twenty-five, Chapter Twenty-seven

WindowList.ahk; Chapter One

WindowMove.ahk; Chapter One

Windows Message System; Chapter Thirty-three, Chapter Thirty-four

Windows Messages, list; Chapter Nine, Chapter Thirty-three

Windows Registry, changing; Chapter Thirty-five

Windows Spy; Chapter Thirty-four

Windows voice; Chapter Thirty-two

WinGet command; Chapter Twelve

WinGetClass, class, ahk_id %id%; Chapter Thirty-four

WinGetPos command; Chapter Nine, Chapter Ten, Chapter Thirty-one

WinGetTitle, title, ahk_id %id%; Chapter Thirty-four

WinRestore; Chapter Eight, Chapter Twelve, Chapter Twenty-two

WinShow command; Chapter Thirty-nine, Chapter Forty

WinToolTipToggle.ahk; Chapter One

WinWait command; Chapter Thirty-nine

WinWaitActivate; Chapter Thirteen

WM_MOUSEMOVE = 0x200; Chapter Thirty-four

Wrap, Gui option; Chapter Seven

Write an e-mail window; Chapter Eleven

X—Index to "AutoHotkey Applications"

XP±n with GroupBox; Chapter Thirteen

XS option (start a new row), Gui format; Chapter Seven

Y—Index to "AutoHotkey Applications"

YP±n with GroupBox; Chapter Thirteen

YYYYMMDD standard date format; Chapter Eleven

YYYYMMDDHHMMSS time format; Chapter Twelve

"A Beginner's Guide to Using Regular Expressions in AutoHotkey" Contents and Index

“The Table of Contents and Index from the e-book "A Beginner's Guide to Using Regular Expressions in AutoHotkey.”

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.

Table of Contents to "A Beginner's Guide to Using Regular Expressions in AutoHotkey"

Foreword

"There is nothing regular about Regular Expressions."

This is not a beginning AutoHotkey book, but a journey into RegEx for AutoHotkey users.

Chapter One: Understanding the Mysteries of Regular Expressions (RegEx) in AutoHotkey

"To Understand How a RegEx Works, It Helps to See Trains Running Down a Track"

Many AutoHotkey script writers don't use Regular Expressions because they seem too mysterious and confusing. All they really need is a little understanding.

Chapter Two: An Introduction to Easy Regular Expressions (RegEx) in AutoHotkey

"A quick guide to understanding how Regular Expressions (RegEx) work in AutoHotkey."

Regular Expressions (RegEx) are notorious for driving people insane, but taken a little at a time they can be simple.

Chapter Three: AutoHotkey RegExMatch() Versus RegExReplace()

"AutoHotkey Regular Expression functions (RegEx) can make complex text extractions and replacements easy."

Although RegEx in AutoHotkey can be confusing, it's worth the time to learn how to use the functions RegExMatch() and RegExReplace() for the power they deliver to your scripts.

Chapter Four: Simplified Regular Expressions in AutoHotkey

"More Regular Expression Tricks with Numbers for AutoHotkey Validation"

This time there are more simple examples of how to use RegEx functions to manipulate data in AutoHotkey.

Chapter Five: Eliminating Double Words with RegEx

"How to Use AutoHotkey RegEx to Eliminate Duplicate Words—RegExReplace()"

Digging deeper into AutoHotkey RegEx with an expression that will find and remove double words in any text, anywhere.

Chapter Six: Fixing Contractions with RegEx

"RegEx can fix multiple errors in contractions such as isn't and won't—RegExReplace()"

Another practical example of a Regular Expression in AutoHotkey with word contractions.

Chapter Seven:A Simple Beginner's Trick for Swapping Letters and Words

"An AutoHotkey Technique for Swapping the Order of Words—RegExReplace()"

Jack shows some easy AutoHotkey techniques for swapping errant letters or words, then step-by-step builds a Regular Expression (RegEx) for doing the same thing and more—with only one line of code.

Chapter Eight: A Simple Way to Find Out Where in the World That IP Address Is Located

"Find IP Addresses in E-mail, Documents and Web Pages, Then Automatically Locate Them!—RegExMatch()"

Have you ever wanted to know where that Spam is coming from or the geographic location of an IP address? This short AutoHotkey script extracts IP addresses from any selected text and downloads its world location from the Web.

Chapter Nine: Stripping Out HTML Tags

"How to extract and save the text from a web page—RegExReplace()"

Learn how to strip HTML tags from Web pages with AutoHotkey RegEx.

Chapter Ten: An App for Extracting Web Links from Web Pages

"Web Link Extractor AutoHotkey Scripts—RegExMatch()"

Need to save Web links from Web pages? Here are two AutoHotkey scripts which do the job.

Chapter Eleven: Verifying E-mail Addresses with AutoHotkey

"How e-mail address checking works with AutoHotkey RegEx."

There are plenty free Regular Expression (RegEx) examples on the Web. The problem is that they do not all work as advertised.

Chapter Twelve: Look-Ahead and Look-Behind RegEx Mysteries

"Look in front of and behind the Haystack for RegEx signposts to create a match."

A look at the confusing world of look-ahead and look-behind assertions in AutoHotkey RegEx. See how they can extend the power of Regular Expressions.

Chapter Thirteen: Using RegEx Property Symbols

"RegEx Properties \p{xx} extend the flexibility of Regular Expressions."

Use properties (\p{xx}) in AutoHotkey RegEx to correct punctuation, change currency symbols, and remove sets of brackets and parentheses.

Index to "A Beginner's Guide to Using Regular Expressions in AutoHotkey"

$ end or terminating anchor; Chapter Four; Chapter Eleven

(…) order of evaluation, capture special features, or change options; Chapter Eleven

* Match preceding 0 or more times; Chapter Eleven

^ Do not match inside a range [^…]; Chapter Four

^ Front end or beginning anchor; Chapter Four; Chapter Eleven

^ Circumflex; Chapter Four

^\d. Exclude all digits and decimal points; Chapter Four

. (dot) is the wildcard for any character; Chapter Two; Chapter One

. (dot) as a decimal point or period; Chapter Two

.*? Question mark to eliminate greed; Chapter Nine

(?!, California) Negative look-ahead assertion; Chapter Twelve

(?<!Los Angeles, ) Negative look-behind assertion; Chapter Twelve

(?<=...) Look-behind assertion; Chapter Twelve

(?=, California) Look-ahead assertion; Chapter Twelve

? Look-ahead and look-behind assertions; Chapter Twelve

? Negative look-ahead assertion (?!, California); Chapter Twelve

? Optional expressions \S?; Chapter Seven

? Optional match; Chapter Four; Chapter Eleven

? Question mark to eliminate greed .*?; Chapter Nine

?: Do not capture subpattern inside (?:…); Chapter Eight

[^\W] Prevent non-alphanumeric matches; Chapter Eleven

[…] Ranges; Chapter Two

[0-9]+ Repeated range; Chapter Four

[a-z0-9_\.-] Any lowercase letters, numbers, the underline mark, dots, and hyphens; Chapter Eleven

[a-zA-Z0-9] All letters and numeric digits; Chapter Two

\ Backslash not required within range to escape dot .; Chapter Eleven

\ Backslash, escape character; Chapter Two

\. Dot escape sequence; Chapter Two; Chapter Eleven

\b Word match boundary; Chapter Five; Chapter Thirteen

\d Same as [0-9] or [0123456789]; Chapter Two; Chapter Four; Chapter Eleven

\d{1,3} 0 to 9 at least once no more than three times; Chapter Eight

\K Look behind assertion; Chapter Twelve

\p{P} Match any punctuation; Chapter Thirteen

\p{Pe} Match end or close bracket or parenthesis; Chapter Thirteen

\p{Ps} Match start or open bracket or parenthesis; Chapter Thirteen

\p{S} Match any symbol; Chapter Thirteen

\p{Sc} Match any currency symbol; Chapter Thirteen

\p{xx} Properties; Chapter Thirteen

\s Space; Chapter Five

\W any non-alphanumeric character; Chapter Eleven

\w Match any letter or digit, [a-zA-Z0-9]; Chapter Thirteen; Chapter Four; Chapter Two

`n for newline or linefeed; Chapter Five

`r for carriage return; Chapter Five

{2,6} min two and max six of preceding range; Chapter Eleven

{min,max} Match preceding at least min and no more than max times; Chapter Four; Chapter Six; Chapter Seven; Chapter Eight; Chapter Eleven

+ Match preceding 1 or more times; Chapter Two; Chapter Five; Chapter Eleven

+ Similar to the star *, but is used to match one or more; Chapter One

<a href="URL">Link Text</a>; Chapter Ten

Regular Expressions (RegEx) A-C

Alternative matches; Chapter Seven

AutoHotkey Forum; Chapter Eight

AutoHotkey_L RegEx Tester (Ryan's); Chapter One

AutoHotkey_L support; Chapter Thirteen

Backreference; Chapter Six; Chapter Seven; Chapter Eight; Chapter Eleven

Backreference as replacement; Chapter Five

Backreference in the expression; Chapter Five

Backreference to make the match; Chapter Five

Break; Chapter Eight

Case insensitive option; Chapter Five

Changing and rearranging data, RegExReplace(); Chapter One

Circumflex ^ different meanings; Chapter Four

Clipboard := SubStr(Clipboard,2); Chapter Seven

ClipWait command; Chapter Seven; Chapter Eight

ComObjCreate("WinHttp.WinHttpRequest.5.1"); Chapter Eight

ComObjCreate() function; Chapter Eight

Contractions, fix multiple errors; Chapter Six

CountIP++; Chapter Eight

Regular Expressions (RegEx) D-F

Dot (.) not used inside a range; Chapter Two

Dot (.) used inside a range; Chapter Two

Duplicate words in text; Chapter Five

Eliminate loops when possible; Chapter Ten

Eliminating extra spaces; Chapter Five

E-mail address validation; Chapter Eleven

Extracting and replicating data, RegExMatch(); Chapter One

Extracting IP addresses; Chapter Eight

Extracting, Web links from a Web page; Chapter Ten

FileAppend command; Chapter Nine; Chapter Ten

FileDelete command; Chapter Nine; Chapter Ten

FileRead command; Chapter Nine; Chapter Ten

Forcing a number type from a string; Chapter Four

FoundPos; Chapter Two

Regular Expressions (RegEx) G-L

Greed; Chapter Nine

Haystack; Chapter Two

History of Regular Expressions; Chapter One

How RegEx Works; Chapter Two

HTML language; Chapter Nine

HTML source code, stripping out; Chapter Nine

HTML tags; Chapter Ten

HTTP(S):// RegEx; Chapter Ten

i) Option, ignore case; Chapter Thirteen

InStr() function; Chapter Seven

IP address matching; Chapter Eight

Kleene plus +; Chapter One

Kleene star *; Chapter One

Line continuation; Chapter Seven

List of useful RegEx properties \p{xx}; Chapter Thirteen

Locate duplicate words; Chapter Five

Look-ahead assertions; Chapter Twelve

Look-behind assertions; Chapter Twelve

Loop command; Chapter Eight; Chapter Ten

Loop, using RegExMatch() in; Chapter Two

Regular Expressions (RegEx) M-O

Mark double words; Chapter Five

Matching contractions; Chapter Five

Matching more than one IP address; Chapter Eight

Matching the end of a string; Chapter Four

Matching words only; Chapter Five

MatchObject; Chapter Five; Chapter Eight; Chapter Eleven

Needle in a haystack; Chapter Two

NeedleRegEx; Chapter Two

Non-greedy mode; Chapter Ten

Numeric digit wildcard (\d); Chapter Three

Numeric location in Haystack; Chapter Two

O) MatchObject Option; Chapter Five; Chapter Eight; Chapter Eleven

Object Oriented Programming (OOP); Chapter Five

Object properties; Chapter Five

Optional \S? expressions; Chapter Seven

Regular Expressions (RegEx) P-R

P) Position Option; Chapter Five

Parse a number from the title of a window; Chapter Three

Properties, using in RegEx \p{xx}; Chapter Thirteen

Pseudo-array; Chapter Eight

Punctuation mark, match; Chapter Thirteen

Ranges in RegEx matches[…]; Chapter Three; Chapter Two

Reference online RegEx; Chapter Two

Reformatting data, RegExReplace(); Chapter Three

RegEx history; Chapter One

RegEx Options; Chapter Five

RegEx Quick Reference; Chapter Two

RegEx Tester (Robert Ryan); Chapter Three; Chapter Eight

RegEx Tester script; Chapter One

RegEx Tester using; Chapter Five

RegExMatch() and RegExReplace(), differences and uses; Chapter Two

RegExMatch() for extracting data; Chapter Three

RegExMatch() function; Chapter One; Chapter Two; Chapter Three; Chapter Four; Chapter Eight; Chapter Eleven

RegExMatch() is for mining, extracting, and replicating data; Chapter One

RegExMatch(), using in Loop; Chapter Two

RegExReplace(); Chapter Two

RegExReplace(); Chapter One

RegExReplace() for correcting data; Chapter Three

RegExReplace() for reformatting data; Chapter Three

RegExReplace() is for changing and rearranging; Chapter One

RegExReplace(); Chapter One; Chapter Three; Chapter Four; Chapter Seven; Chapter Nine

Regular Expression testing app; Chapter One

Regular Expressions (RegEx or RegExp); Chapter Two

Remove all non-numeric characters; Chapter Three

Remove all of the letters (upper and lowercase) in a variable; Chapter Four

Removing unwanted characters; Chapter Four

Repeated expression in parentheses; Chapter Eight

Retrieval of Web page data; Chapter Eight

Retrieve IPs geographic location; Chapter Eight

Run command; Chapter Nine; Chapter Ten

Ryan's Regular Expression testing app; Chapter One

Regular Expressions (RegEx) S-T

Saving RegEx matches to a variable; Chapter Two

SendInput, ^c; Chapter Seven

SetFormat command; Chapter Four

Sleep command to delay script execution; Chapter Eight

StringGetPos command; Chapter Seven

StringReplace command; Chapter Nine

StringTrimRight; Chapter Three

Stripping out HTML code; Chapter Nine

StrLen() function; Chapter Eight

Subpattern (…); Chapter Ten; Chapter Eleven

Sub-reference; Chapter Ten

SubStr() function; Chapter Four; Chapter Seven

SubStr(Clipboard,1,1); Chapter Seven

Swapping contractions in text; Chapter Seven

Swapping letters in text; Chapter Seven

Swapping two words in text; Chapter Seven

Test script, Ryan's; Chapter Two

Testing a RegEx; Chapter Eleven

Testing RegEx, a simple script; Chapter Eleven

Regular Expressions (RegEx) U-W

UrlDownloadToFile command; Chapter Eight; Chapter Nine; Chapter Ten

Validating number fields; Chapter Four

Various RegEx options; Chapter Two

Web links from a Web page, extracting; Chapter Ten

Web to retrieve the IP's geographic location; Chapter Eight

Wildcard, dot (.); Chapter Eight

Word boundary \b; Chapter Five

"Beginning AutoHotkey Hotstrings" Contents and Index

A Practical Guide for Creative Autocorrection, Text Expansion, and Text Replacement

“The Table of Contents and Index from the e-book "Beginning AutoHotkey Hotstrings.”

Hotstrings are only one piece of the extensive AutoHotkey Windows scripting language, but if you're a writer, editor, programmer, or word processing professional of any type, then you have a reason to use AutoHotkey Hotstrings. Whether you need to AutoCorrect your writing in any Windows application or on any Web site; want to quickly expand abbreviations; create menus of options for text replacement; or build lists of business or professional jargon for quick insertion, AutoHotkey is the ticket for you. The strength of AutoHotkey Hotstrings is that they are simple to implement, yet powerful tools. Plus, the software is free!

The primary focus of Beginning AutoHotkey Hotstrings is text replacement and text expansion, although almost anything that can be done with Hotkeys can be done with "action" Hotstrings. The beauty of AutoHotkey Hotstrings is that virtually anyone can learn to use them with little or no programming background. The basic Hotstring script may contain only one line of code standing on its own. The most popular use of Hotstrings is a series of these one-liners making up AutoHotkey text AutoCorrect apps—working in any Windows text editing or input field—whether a word processing program or Web page.

One of the great things about starting your AutoHotkey journey with Hotstrings is that it is some of the easiest scripting that you can do. All you need is a Windows text editor (Notepad). Then, as you add Hotstrings one line at a time, you become much more comfortable with the process—making it easier to include more advanced features. That's how this book is organized. It begins with the basics of AutoHotkey Hotstrings building on each chapter, concluding with techniques which venture into the intermediate (or even advanced) level in the last chapter.

Beginning AutoHotkey Hotstrings offers practical examples and techniques for getting the most out of this unique scripting language. If you're an experienced programmer, then you won't need this book—unless you're just looking for more ideas on how you might use AutoHotkey. The techniques are simple and straightforward while uncovering many of the more subtle possibilities.

The topics include adding menus and pop-up windows to your AutoHotkey Hotstrings, The last two chapters even explore the little known, yet powerful Input command.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.

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. For more details about Beginning AutoHotkey Hotstrings (Table of Contents and the entire book index), read on!

Table of Contents

Chapter One: AutoHotkey Hotstrings for AutoCorrect, Text Insertion, and Text Expansion

AutoHotkey Hotstring Basics; How Hotstrings Work in Their Most Basic Form; Basic Hotstring Techniques in AutoCorrection; Getting the Most Out of AutoHotkey Hotstrings; Adding Your Signature to Anything; Adding Blocks of Text

Chapter Two: Add AutoCorrect to All Your Windows PC Programs with AutoHotkey

For People Who Fall Victim to Typos and Common Misspellings; How AutoCorrect Works; Fancy Foreign Words in English; Pet Peeves

Chapter Three: Beginning Tips for AutoHotkey Hotstring Text Correction and Text Expansion (Hotstring Options * and ?)

Practical Ways to Use Instant Replacement (*) and Internal Word Text Replacement (?) in Your AutoHotkey Hotstring AutoCorrect Script; Hotstring Options * and ?; Fixing the "HT" Typo

Chapter Four: Beginning Tips for AutoHotkey Hotstring Text Correction and Text Expansion (Hotstring Options B0, C and O)

Practical Ways to Use No Backspace (B0), Case Sensitive (C), and Omit Last Character (O) Options in Your AutoHotkey Hotstring AutoCorrect Script; Expanding Abbreviations; Capitalization Issues; Automatically Adding Script and Programming Codes; Expanding Abbreviations with the No Backspace (B0), Case Sensitive (C), and Omit Last Character (O) Options; Using the C Option for the Word AutoHotkey; The B0 Option for Inserting HTML Tags or Program Command Formats; The O Option to Omit the Activation Character

Chapter Five: Adding Action to AutoHotKey HotStrings, Plus a Trick for Creating IF Conditional Hotstring Text Replacements

How to Add Action to AutoHotKey Hotstrings; Solving an AutoCorrect Problem with IF-ELSE Conditions; Hotstrings Running AutoHotKey Routines; A Technique for Creating Conditional IF-ELSE Hotstrings; Selecting Text for Clipboard Manipulation; Fixing the Swapped Letters in THTP in AutoCorrect

Chapter Six: A Beginner's Trick for Inserting Next Friday's Date and an Important Tip for Any AutoHotkey User

A Novice AutoHotkey Trick for Inserting Next Friday's Date and a Possible Solution for Failing Hotkeys

Chapter Seven: Turning a Simple Date Trick into an Easy AutoHotkey Function

If You Need to Do It Over and Over Again, Make It an AutoHotkey Function; Debugging Tip for Mixed Variable Types; Adding the Hotstrings

Chapter Eight: Make Your Own Text AutoCorrect Hotstring Pop-up Menus with AutoHotkey

Sometimes a Common Misspelling Has More Than One Possible Replacement Word. Here's How to Add an AutoHotkey Pop-up Menu for Easy Word Selection; Adding Menu Options to Hotstrings

Chapter Nine: How to Turn AutoHotkey Hotstring AutoCorrect Pop-up Menus into a Function

Save Redundant AutoHotkey Code by Creating a Function for Pop-up Hotstring Menus

Chapter Ten: Add Currency (and Other) Symbols with AutoHotkey Hotstring Menus

Use AutoHotKey Hotstring Menus to Add Currency Symbols to Any Windows Program or on the Web; Adding Fractions to a Menu; Adding Math Symbols to a Menu

Chapter Eleven: Replacing Overused Words with Pop-up Synonym Menus

Whether You're a Student or Merely Want to Improve Your Writing, Use Hotstring Menus to Insert Substitutes for Over Abused Words…Plus Another Free AutoHotkey Script!

Chapter Twelve: More Pop-up Synonym Menu Tips for AutoHotkey Hotstrings

The C Option (Case Sensitive)—An Easy Way to Limit Hotstring Action. Plus, How to Emulate Hotstring Capitalization in an Action Menu Subroutine; Passing through Capitalization in Action Hotstrings

Chapter 13: Instantly Add Dates to Your Documents in Different Formats with Hotstring Menus

Don't Know Which Time or Date Format You Need for Your Next Document or Web Form? Pick from a Hotstring Menu of Options.

Chapter Fourteen: Inserting Future (or Past) Dates and Times with AutoHotkey GUIs and Hotstring Menus

Add Methods for Inserting Any Future or Past Date or Time into Your Windows and Web Documents with AutoHotkey GUI (Graphical User Interface) Pop-ups Using Hotstring Menus; Expanding the Date/Time Hotstring Menu with Future and Past Options; Building a GUI (Graphical User Interface); Destroying the GUI to Prevent Errors; What about the Time?

Chapter Fifteen: Inserting Future (or Past) Dates and Times with AutoHotkey GUIs and Hotstring Menus (continued)

Using the DateTime GUI to Enter Both Times and Dates into the AutoHotkey Hotstring Replacement Menus; Tracking the Original Edit Window

Chapter Sixteen: Create Instant Temporary AutoHotkey Hotstrings with the Input Command

For Those Times When All You Need for Special Tasks Is Temporary Hotstrings, Use the AutoHotkey Input Command; The AutoHotkey "Input" Command; How the "Input" Command Works; No True Value Found; State Abbreviation Text Replacement; A Quirk of the Input Command; Other Uses of the Input Command

Chapter Seventeen: Reduce Code and Increase Power with the AutoHotkey Input Command

Use the Input Command to Eliminate Code While Creating Multiple Hotstrings. You're Going to Like This One! It Includes Arrays and Hiding Data in Substrings.; Converting the Script for the Input Command; AutoHotkey Variable Arrays; Storing Data in a Text Strings; Take It to the Next Step

Index to Beginning AutoHotkey Hotstrings

#

#If command Chapter Sixteen

#IfWinActive command Chapter Sixteen

*

* Option, immediate activation Chapter Three, Chapter Four, Chapter Ten

?

? Option, activate inside string Chapter Three, Chapter Ten

`

`t why not to use TAB for an activating character Chapter Thirteen

`t, TAB character Chapter One, Chapter Four, Chapter Ten

{

{alt} Chapter One

{Backspace} Chapter Five

{Enter} Chapter One

{Left 4} Chapter Five

{Raw} Chapter Nine, Chapter Thirteen, Chapter Fourteen, Chapter Fifteen

{Return} Chapter One, Chapter Four

{Shift down} Chapter Five, Chapter Twelve

{Shift up} Chapter Five, Chapter Twelve

{Space} Chapter One, Chapter Four

{Tab} Chapter One

A — Beginning AutoHotkey Hotstrings Index

A Beginner's Guide to AutoHotkey Chapter Thirteen, Chapter Fourteen, Author

A_CaretX built-in variable Chapter Sixteen

A_CaretY built-in variable Chapter Sixteen

A_EndChar Hotstring variable Chapter Five

A_Index built-in variable (Loop) Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen

A_Now, built-in variable Chapter Six, Chapter Thirteen

A_ThisMenuItem. built-in Menu variable Chapter Eight

A_WDay, built-in variable Chapter Six, Chapter Seventeen

Abbreviations, expanding Chapter Four, Chapter Four

Add symbols to Hotstring menus Chapter Ten, Chapter Ten

Adding blocks of text Chapter One

Adding Fractions to a Menu Chapter Ten

Adding Math Symbols to a Menu Chapter Ten

Array techniques Chapter Seventeen

Array, Associative Chapter Seventeen

Arrays Chapter Seventeen

Associative Array Chapter Seventeen

Auto-execute section of script Chapter Five

AutoCorrect Chapter One, Chapter Two, Chapter Three, Chapter Five, Chapter Eight, Chapter Sixteen

AutoCorrect.exe Chapter Two

AutoHotkey Applications E-book Chapter Fourteen, Author

AutoHotkey books Copyright, ForeWord, Chapter One, Chapter Five, Chapter Ten, Chapter Fourteen, Author

AutoHotkey Functions Chapter Seven, Chapter Seven, Chapter Nine

AutoHotkey installation Chapter One

AutoIt software Chapter One

B — Beginning AutoHotkey Hotstrings Index

B0 Option no backspace Chapter Four, Chapter Five, Chapter Eleven, Chapter Thirteen

Blocks of text, adding Chapter One

Break command Chapter Nine

Button, Submit Chapter Fourteen

C — Beginning AutoHotkey Hotstrings Index

C Option case sensitive Chapter Five, Chapter Twelve, Chapter Thirteen

CharMap, open in Windows Chapter Ten

CharMap, special characters Chapter Ten

Clipboard, saving contents Chapter Five

Clipboard, Windows Chapter Five, Chapter Twelve

ClipWait command Chapter Five

Combining strings, concatenation Chapter Thirteen, Chapter Seventeen

Commands

#If Chapter Sixteen

#IfWinActive Chapter Sixteen

Break (Loop) Chapter Nine

ClipWait Chapter Five

DateTime GUI control Chapter Fifteen

EnvAdd (+=) Chapter Six, Chapter Seven

FormatTime Chapter Five, Chapter Six, Chapter Seven, Chapter Thirteen, Chapter Fifteen

Global Chapter Eleven, Chapter Thirteen

GUI (Graphical User Interface) Chapter Fourteen, Chapter Fourteen, Chapter Fourteen

Gui, Add Chapter Fourteen, Chapter Fifteen

GUI, Destroy Chapter Fourteen

Gui, Show Chapter Fourteen

Gui, Submit Chapter Fourteen

If Chapter Five

IfWinExist Chapter Fourteen

Input Chapter Sixteen, Chapter Seventeen

InputBox Chapter Seventeen

Loop Chapter Nine

Menu Chapter Eight

Menu, Add Chapter Nine

MonthCal GUI control Chapter Fourteen, Chapter Fifteen

MsgBox Chapter Five, Chapter Sixteen, Chapter Seventeen

Return Chapter Five, Chapter Thirteen

Send Chapter One, Chapter Sixteen

SendInput Chapter Five, Chapter Six, Chapter Eight, Chapter Twelve, Chapter Thirteen, Chapter Seventeen

SendMode (problem?) Chapter Six

SendRaw Chapter Nine

StringSplit Chapter Nine, Chapter Seventeen

StringSplit (parsing) Chapter Nine, Chapter Seventeen

WinActivate Chapter Thirteen, Chapter Fifteen

WinGet Chapter Fifteen

Concatenation (combining strings) Chapter Thirteen, Chapter Seventeen

Context sensitive Hotstrings Chapter Sixteen

Currency symbol menus Chapter Ten, Chapter Ten

D — Beginning AutoHotkey Hotstrings Index

Date format, LongDate Chapter Seven, Chapter Thirteen, Chapter Seventeen

Dates, Hotstring menus Chapter Thirteen

DateTime GUI control Chapter Fifteen

Debugging tip Chapter Seven

Delete Menu items Chapter Eight, Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen

Delimiting (separating) characters Chapter Nine, Chapter Thirteen

Destroying the GUI to prevent errors Chapter Fourteen

Download Free AutoHotkey Scripts and Apps

Chapter Six, Chapter Eleven, Chapter Twelve, Chapter Sixteen

Download site Chapter Eleven, Chapter Twelve, Chapter Fourteen, Chapter Fifteen, Chapter Sixteen

Dropbox download site Chapter Fourteen, Chapter Fifteen, Chapter Sixteen

E — Beginning AutoHotkey Hotstrings Index

EnvAdd command (+=) Chapter Six, Chapter Seven

ErrorLevel, Input command Chapter Sixteen, Chapter Seventeen

Expanding abbreviations Chapter Four, Chapter Four

F — Beginning AutoHotkey Hotstrings Index

FormatTime command Chapter Five, Chapter Six, Chapter Seven, Chapter Thirteen, Chapter Fifteen

Free AutoHotkey scripts Chapter Eleven, Chapter Twelve, Chapter Sixteen

Free AutoHotkey Scripts and Apps Chapter Six, Chapter Eleven, Chapter Twelve, Chapter Sixteen

Functions,

User Defined Chapter Seven

WinActive() Chapter Fifteen, Chapter Sixteen

Writing Chapter Seven, Chapter Seven, Chapter Nine

G — Beginning AutoHotkey Hotstrings Index

gLabel option, Gui command Chapter Fourteen

Global command Chapter Eleven, Chapter Thirteen

Global variables Chapter Eleven, Chapter Thirteen

Graphical User Interface (GUI) pop-up Chapter Fourteen, Chapter Fourteen, Chapter Fourteen

GUI (Graphical User Interface) command Chapter Fourteen, Chapter Fourteen, Chapter Fourteen

Gui command, gLabel option Chapter Fourteen

Gui, Add command Chapter Fourteen, Chapter Fifteen

GUI, Destroy command Chapter Fourteen

GUI, destroying the to prevent errors Chapter Fourteen

Gui, Show command Chapter Fourteen

Gui, Submit command Chapter Fourteen

GuiClose Label Chapter Fourteen

H — Beginning AutoHotkey Hotstrings Index

Hiding data in substrings Chapter Seventeen

Hotkey modifiers Chapter One

Hotkeys Chapter Sixteen

Hotstring

Replacement Chapter One

Text expansion ForeWord, Chapter One, Chapter Three, Chapter Four, Chapter Five, Chapter Sixteen

Hotstring Options

* Immediate activation Chapter Three, Chapter Four, Chapter Ten

?, activate inside string Chapter Three, Chapter Ten

B0 No backspace Chapter Four, Chapter Five, Chapter Eleven, Chapter Thirteen

C Case sensitive Chapter Five, Chapter Twelve, Chapter Thirteen

O Omit the ending (activation) character Chapter Four

Hotstring pop-up menus Chapter Eight

Hotstrings

Adding blocks of text Chapter One

Context sensitive Chapter Sixteen

Keylist, special keys and characters Chapter One

Multiple lines Chapter One

Temporary Chapter Sixteen

{alt} Chapter One

{Enter} Chapter One

{Raw} Chapter Nine, Chapter Thirteen, Chapter Fourteen, Chapter Fifteen

{Return} Chapter One, Chapter Four

{Shift down} Chapter Five, Chapter Twelve

{Shift up} Chapter Five, Chapter Twelve

{Space} Chapter One, Chapter Four

{Tab} Chapter One

Hotstrings, temporary Chapter Sixteen

HTML tags Chapter Four

http Chapter One, Chapter Three, Chapter Five

I — Beginning AutoHotkey Hotstrings Index

If command Chapter Five

IfWinExist command Chapter Fourteen

Images of AutoHotkey GUI Control Popup Windows Chapter Fourteen

Input command Chapter Sixteen, Chapter Seventeen

Input command problem Chapter Sixteen

Input command, ErrorLevel Chapter Sixteen, Chapter Seventeen

Input command, when to use Chapter Sixteen

InputBox command Chapter Seventeen

Insert date into text Chapter Five

Insert US states Chapter Sixteen

Inserting HTML tags Chapter Four

Install AutoHotkey Chapter Two

Installing AutoHotkey Chapter One

K — Beginning AutoHotkey Hotstrings Index

Keyboard action, simulate Chapter Five

Keylist, special keys and characters Chapter One

L — Beginning AutoHotkey Hotstrings Index

Label subroutine Chapter Eight

Label, Gui gLabel option Chapter Fourteen

Label, GuiClose Chapter Fourteen

Line continuation Chapter Twelve, Chapter Fifteen, Chapter Sixteen, Chapter Seventeen

Lists of common misspellings Chapter Two

LongDate format Chapter Seven, Chapter Thirteen, Chapter Seventeen

Loop command Chapter Nine

M — Beginning AutoHotkey Hotstrings Index

Menu command Chapter Eight

Menu items, Delete Chapter Eight, Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen

Menu, Add command Chapter Nine

Menus

Add symbols Chapter Ten, Chapter Ten

Currency Symbols Chapter Ten, Chapter Ten

Dates Chapter Thirteen

Synonyms Chapter Eleven

Misspellings Chapter Two

Modifiers, Hotkey Chapter One

MonthCal GUI control Chapter Fourteen, Chapter Fifteen

MsgBox command Chapter Five, Chapter Sixteen, Chapter Seventeen

Multiple line Hotstrings Chapter One

Multiple misspelling replacements Chapter Eight

O — Beginning AutoHotkey Hotstrings Index

Object model Chapter Seventeen

Object model, array techniques Chapter Seventeen

Object Oriented Programming (OOP) Chapter Seventeen

Omit the ending (activation) character (O option) Chapter Four

OverusedWords.ahk Chapter Eleven, Chapter Twelve

P — Beginning AutoHotkey Hotstrings Index

Parse Chapter Nine, Chapter Twelve, Chapter Seventeen

Pop-up menus, Hotstring Chapter Eight

R — Beginning AutoHotkey Hotstrings Index

Return command Chapter Five, Chapter Thirteen

S — Beginning AutoHotkey Hotstrings Index

Script download site Chapter Eleven, Chapter Twelve

Script writing Chapter Two

Scripts AutoHotkey (free) Chapter Eleven, Chapter Twelve, Chapter Sixteen

Send command Chapter One, Chapter Sixteen

SendInput command Chapter Five, Chapter Six, Chapter Eight, Chapter Twelve, Chapter Thirteen, Chapter Seventeen

SendMode command (problem?) Chapter Six

SendRaw command Chapter Nine

Simulate keyboard action Chapter Five

Special Characters Chapter Two, Chapter Ten

Storing data in a text strings Chapter Seventeen

StringSplit command Chapter Nine, Chapter Seventeen

StringSplit command (parsing) Chapter Nine, Chapter Seventeen

Submit Button Chapter Fourteen

Subroutine, gLabel option Chapter Fourteen

Subroutine, Label Chapter Eight

Symbols Chapter Two, Chapter Nine, Chapter Ten

Symbols, adding to Hotstring menus Chapter Ten, Chapter Ten

Synonym menus Chapter Eleven

Synonyms For Words Commonly Used In Student's Writings Chapter Eleven

T — Beginning AutoHotkey Hotstrings Index

TAB character `t Chapter One, Chapter Four, Chapter Ten

Temporary Hotstrings Chapter Sixteen

Tracking the original window Chapter Fifteen

U — Beginning AutoHotkey Hotstrings Index

US states, insert from mail codes Chapter Sixteen

Use and Images of AutoHotkey GUI Control Popup Windows Chapter Fourteen

User Defined Functions Chapter Seven

V — Beginning AutoHotkey Hotstrings Index

Variables Built-in

A_CaretX Chapter Sixteen

A_CaretY Chapter Sixteen

A_EndChar Chapter Five

A_Index (Loop) Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen

A_Now Chapter Six, Chapter Thirteen

A_ThisMenuItem. Menu variable Chapter Eight

A_WDay Chapter Six, Chapter Seventeen

W — Beginning AutoHotkey Hotstrings Index

When to use the Input command Chapter Sixteen

WinActivate command Chapter Thirteen, Chapter Fifteen

WinActive() function Chapter Fifteen, Chapter Sixteen

Window, tracking Chapter Fifteen

Windows CharMap Chapter Ten

Windows Clipboard Chapter Five, Chapter Twelve

WinGet command Chapter Fifteen

Writing AutoHotkey Functions Chapter Seven, Chapter Seven, Chapter Nine

AutoHotkey Hotkeys: Tips, Tricks, Techniques, and Best Practices for Automating Your Windows Computers with Hotkey Combinations—Something for Everyone!

Whether you're a noobie to AutoHotkey scripts or an advanced programmer, of all my books, AutoHotkey Hotkeys may be the most important for little-known tricks and useful ideas. It's not that the other books don't cover significant features of AutoHotkey, but this book includes some of the most practical tips for adding power to your scripts. I didn't plan it that way.

In the course of writing the individual chapters I experienced a number of personal epiphanies. A few "Best Practices" slowly became obvious as I worked with particular commands. The power of #IfWin directives opened my eyes as I searched for practical applications for Hotkeys. The usefulness of Scan Codes versus Virtual keys became apparent once I understood how they work. Plus, the writing process sparked insight into how to make any AutoHotkey command more powerful with forced expressions (%) and the ternary operator. The book starts at a beginning level (Chapter One), but it quickly builds upon the basic Hotkey structure to introduce more advanced techniques—including detailed discussions of the unique Hotkey command. Writing this book turned into a trip of discovery. I merely followed where the AutoHotkey commands and features led me.

Hotkey Best Practices

I didn't introduce the concepts which I now recognize as "Best Practices" until Chapter Fifteen. Prior to that, even though I had discussed the pertinent techniques, the working details of the various commands took up my focus. When I began working on the Hotkey summary script MousePrecise.ahk, it dawned on me that I could and should apply a few of these tricks to almost all my Hotkeys. From of that insight grew a few thumb rules.

Thumb Rule #1: Whenever possible isolate Hotkey functions to only those programs (windows) where you need them.

The IfWinActive command (Chapter Two) and the #IfWinActive directive (Chapter Three) act as the primary methods for restricting context-sensitive Hotkeys to particular apps and windows.

Thumb Rule #2: Save code and add flexibility to the #IfWinActive directive by using the GroupAdd command to include more apps in the Hotkey restrictions.

Using the GroupAdd command to include programs classes in the InWinActive/#IfWinActive statements overcomes the command/directive's inflexibility (Chapter Four).

Thumb Rule #3: Make a habit of adding important Hotkey actions to the System Tray icon menu.

If you use numerous Hotkeys, it only makes sense to add them to the System Tray icon right-click menu (Chapter Twenty). Otherwise, you may find it impossible to remember them all.

Thumb Rule #4: When using the Windows Clipboard for copying selected text, add basic structure which includes standard commands.

In the years that I've used AutoHotkey, I found that a number of commands should be part of the standard clipboard manipulation routine. Those techniques include saving contents of the Windows Clipboard (ClipboardAll) for later restoration, waiting for the clipboard to load (ClipWait command), and using ErrorLevel for Hotkey misfires. Chapter Nine explains how to implement each of these techniques when using the Windows Clipboard to trigger AutoHotkey routines and manipulate text.

Understanding and Using #Directives

New AutoHotkey users often struggle with the difference between regular commands and #Directives. Using the wrong one at the wrong time doesn't work—and the error may not be obvious. Chapter Three discusses "Commands Versus #Directives."

The Power of Forced Expressions and the Ternary Operator

Occasionally, I experience an insight which has a profound impact on how I write AutoHotkey commands. One such revelation inspired by AutoHotkey forced-expressions brings my scripts to another level. This realization may be the single most important capability for adding conditional features to any AutoHotkey command.

“Hey! Pay attention! This part is really important!” Forced expressions—especially in combination with the single-line Ternary Operator can add incredible power to virtually any AutoHotkey command. Forced expressions initiate the jump from staid fix syntax formats and options to flexible conditionals embedded inside any command. Chapter Seventeen, "Force an Expression (%) in AutoHotkey for More Powerful Commands" and Chapter Eighteen, "AutoHotkey Toggles and the Ternary Operator" offer tricks that any AutoHotkey user will want to use.

Keyboard Scan Codes Versus Virtual Keys

A book about AutoHotkey Hotkeys wouldn't be complete without a discussion of keyboard Scan Codes and Virtual Keys. Chapter Twelve, "Understanding AutoHotkey Keyboard Scan Codes and Virtual Key Codes" highlights the difference between AutoHotkey Keyboard Scan Codes (SCnnn) and Virtual Key Codes (VKnn) and when to use them for Hotkeys. Then, Chapter Thirteen employs methods for writing toddler educational Hotkey scripts to offer practical examples. Plus, the follow-on chapters about the MousePrecise.ahk script make extensive use of these special key codes.

More AutoHotkey Tricks

- Blocking evil Windows shortcuts (Chapter Two)

- Keyless Hotkey volume control (Chapter Six)

- Standardizing Hotkey (shortcut) actions across multiple applications (Chapter Seven)

- Toggling Hotkeys on and off (Chapter Eight)

- ErrorLevel tricks with Hotkeys (Chapter Ten)

- Using the Tooltip command and a quick release Hotkey (Chapter Nineteen)

- Using the extra mouse buttons—XButton (Chapter Twenty-one)

- And more…

The AutoHotkey.com Secret Reference

I consider the hidden index I stumbled upon at AutoHotkey.com so useful that I wrote an AutoHotkey Quick Reference script based upon it. I include a chapter on the site feature in this book (Chapter Twenty-two) and intend to do the same with each of the other books—at least until the secret index disappears again. While this book focuses on Hotkeys, you'll find numerous AutoHotkey tips and tricks valuable for most of your other scripts.

Table of Contents AutoHotkey Hotkeys

Chapter One: Basic Hotkeys—The Gateway to AutoHotkey Script Writing Addiction

With AutoHotkey, It’s So Simple to Add Hotkeys to Your Windows System That You May Not Be Able to Quit; How to Get Addicted to Programming

Chapter Two: Block Windows Shortcuts with AutoHotkey

Block Annoying Computer Shortcuts, Plus Identify Active Windows and Programs with Windows Spy; Override Unwanted Windows Shortcuts with AutoHotkey Hotkeys

Chapter Three: AutoHotkey #Directives for Context-Sensitive Hotkeys—#IfWinActive

Clearing Up the Confusion about AutoHotkey’s IfWinActive Command Versus the #IfWinActive Directive

Chapter Four: The AutoHotkey GroupAdd Command Reduces Script Code

AutoHotkey’s GroupAdd Command and Ahk_Group Create Multiple Context-Sensitive Hotkeys While Streamlining Code—Plus a Quick GroupAdd Script for Easy Window Handling!

Chapter Five: Exploring the Hotkey Command in AutoHotkey

The Hotkey Command Adds Immense Flexibility to AutoHotkey Scripts, But You Should Know How and When to Use It!

Chapter Six: Windows Volume Control Using Your Mouse Wheel and the AutoHotkey #If Directive

The AutoHotkey #If Expression Directive and Hotkey, If (Expression) Command Make Hotkeys Expression-Sensitive, Plus a Simple No-Click Volume Control Script

Chapter Seven: Hotkeys for Deleting Words and Line Segments with AutoHotkey

Standardizing Hotkeys for Deleting Entire Words or Line Segments in Any Windows Program or Web Editing Window

Chapter Eight: Toggling AutoHotkey Hotkeys On and Off

Using the Hotkey Command to Turning Hotkeys On and Off

Chapter Nine: AutoHotkey Windows Clipboard Techniques for Swapping Letters

Delving into Windows Clipboard Hotkey Tricks for Switching Mistyped Letters in Any Document or Text Editor

Chapter Ten: AutoHotkey StringSplit Command and ErrorLevel Tricks for Swapping Words

Techniques for Swapping Words Using the StringSplit AutoHotkey Command; ErrorLevel for Producing Alternative Results; a Glance at a Regular Expression (RegEx) for Swapping Words

Chapter Eleven: AutoHotkey Tips for Mouse Click Hotkeys with Seldom Touched Keys

Make Your Hotkeys Easier by Combining a Rarely Pressed Key and a Simple Mouse Click…or Not! Plus, Take Advantage of More Little Used Keys in Hotkey Combinations

Chapter Twelve: Understanding AutoHotkey Keyboard Scan Codes and Virtual Key Codes

Learn the Difference Between AutoHotkey Keyboard Scan Codes (SCnnn) and Virtual Key Codes (VKnn) and When to Use Them for Hotkeys

Chapter Thirteen: AutoHotkey Scan Codes, Speech, Sound, and Splash Images in Children’s Apps

Write Toddler Educational Hotkey Scripts by Combining AutoHotkey Scan Codes, the SoundPlay Command, the SplashImage Command, and ComObjectCreate() for Speech

Chapter Fourteen: When to Use Virtual Keys and Keyboard Scan Codes with AutoHotkey

Add Missing Keys or Take Advantage of Extra Keyboard Keys with AutoHotkey Scan Codes and Virtual Keys

Chapter Fifteen: AutoHotkey Script for Precision Hotkey Mouse Movement in Windows Graphics Programs

This Short AutoHotkey App Adds Pixel Level Precision to Mouse Cursor Movement in Any Windows Graphics Program. Plus, Best Practices When Creating Hotkeys and More.

Chapter Sixteen: AutoHotkey Script for Precision Hotkey Mouse Movement in Windows Graphics Programs—MousePrecise.ahk Continued

This Short AutoHotkey App Adds Pixel Level Precision to Mouse Cursor Movement in Any Windows Graphics Program

Chapter Seventeen: Force an Expression (%) in AutoHotkey for More Powerful Commands

Learn the Secret of Adding Power and Flexibility to AutoHotkey Commands—Use Forced Expressions to Tailor Almost Anything

Chapter Eighteen: AutoHotkey Toggles and the Ternary Operator

Toggling AutoHotkey Switches, Plus How the Ternary Operator Adds If-Then-Else Conditional Shortcuts to a Single Line of Code

Chapter Nineteen: Tips for Smoothing Out AutoHotkey Scripts with #If, Tooltip, and Quick Release Hotkeys

Enhancing the MousePrecise.ahk AutoHotkey Script with the #If Directive, the Tooltip Command, and a Quick Release Hotkey

Chapter Twenty: Adding Hotkey Actions to Windows System Tray Icon Menu

Adding Hard-to-Remember Hotkeys to the AutoHotkey System Tray Icon Makes Sense—Plus, How to Best Activate the Last Window

Chapter Twenty-one: Multiple Hotkeys and Using The Extra Mouse Buttons

Important Beginning Tips for Assigning Duplicate Hotkeys for the Same Operation and Issues with Using XButtons on Your Mouse

Chapter Twenty-two: Build Your Own AutoHotkey Command Reference Tool (An AutoHotkey Secret)

Learn a Hidden AutoHotkey Trick for Quickly Accessing AutoHotkey Online Command Information AutoHotkey.com Documentation

Index to AutoHotkey Hotkeys

! Hotkey Book

! ALT (Alternate) Key Chapter One, Chapter Eleven, Chapter Fifteen

#

# Windows logo key Chapter One, Chapter Two, Chapter Nine, Chapter Twenty-one

#Directives Introduction, Chapter Two, Chapter Three, Chapter Thirteen

#Directives Versus Commands Introduction, Chapter Three

#Hotstring Chapter Three

#If expression directive Chapter Three, Chapter Six, Chapter Fifteen, Chapter Nineteen

#IfWinActive directive Introduction, Chapter Two, Chapter Three, Chapter Five, Chapter Six, Chapter Thirteen, Chapter Fifteen, Chapter Sixteen

#Include Chapter Three, Chapter Eight

#IncludeAgain Chapter Three

#NoTrayIcon Chapter Three

#Persistent Chapter Three

#SingleInstance off Chapter Three

%

% Force an expression Introduction, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen

&

& Ampersand modifier Chapter Four, Chapter Eleven

^

^ CTRL (Control) Key Chapter One, Chapter Seven, Chapter Eleven, Chapter Sixteen

~

~ option Chapter One, Chapter Eleven

+

+ SHIFT key Chapter One, Chapter Seven, Chapter Nine, Chapter Ten, Chapter Twelve

<

< Left arrow modifier Chapter Eleven

>

> Right arrow modifier Chapter Eleven

A Hotkey Book

A Beginner's Guide to AutoHotkey Author

A_Space Chapter Ten

A_ThisHotkey variable Chapter Five

Action repeated, multiple Hotkeys Chapter Twenty-one, Chapter Twenty-one

Add temporary Hotkeys interactively Chapter Sixteen

ahk_class Chapter Two, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Eight, Chapter Fifteen, Chapter Sixteen

ahk_group Chapter Four, Chapter Five, Chapter Fifteen, Chapter Nineteen

ahk_id Chapter Four, Chapter Six

ALT (Alternate) Key ! Chapter One, Chapter Eleven, Chapter Fifteen

Ampersand (&) modifier Chapter Four, Chapter Eleven

AppsKey Chapter Fourteen

Arrow Modifiers < left and > right Chapter Eleven

ASCII characters Chapter Twelve

Auto-execute section of script Chapter One, Chapter Three, Chapter Four, Chapter Five, Chapter Eight, Chapter Fifteen, Chapter Nineteen, Chapter Twenty-one

AutoHotkey Applications E-book Chapter Eight, Chapter Thirteen, Chapter Seventeen, Author

AutoHotkey books Copyright, Introduction, Chapter Eight, Chapter Seventeen, Chapter Twenty-one, Chapter Twenty-two, Author

AutoHotkey Command Reference Tool Chapter Twenty-two

AutoHotkey file processing Chapter Three

AutoHotkey Functions Chapter Thirteen

AutoHotkey.com documentation Chapter Twenty-two

AutoIt Chapter One

B Hotkey Book

Best Practice #1 (#IfWinActive Directive), Hotkey Chapter Fifteen

Best Practice #2 (GroupAdd Command), Hotkey Chapter Fifteen

Best Practice #3 (add to System Tray menu), Hotkey Chapter Twenty

C Hotkey Book

C Option case sensitive Chapter Three, Chapter Sixteen

Clipboard ErrorLevel message Chapter Nine, Chapter Ten

Clipboard loading lag Chapter Nine

Clipboard Procedures, Standard Format Chapter Nine

Clipboard, Windows Introduction, Chapter Two, Chapter Nine, Chapter Ten

ClipboardAll Introduction, Chapter Nine, Chapter Ten, Chapter Twenty-two

ClipWait command Introduction, Chapter Nine

Combining strings, concatenation Chapter Ten

Command reference tool, AutoHotkey Chapter Twenty-two

Commands

ClipWait Introduction, Chapter Nine

Forced expressions (%) Introduction, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen

GoSub Chapter Eight, Chapter Eleven, Chapter Twenty-one

Goto Chapter Eight

GroupActivate Chapter Four

GroupAdd Introduction, Chapter Four, Chapter Five, Chapter Fifteen, Chapter Sixteen, Chapter Twenty

GUI (Graphical User Interface) Chapter Eight

GuiControl command Chapter Thirteen

Hotkey Introduction, Chapter One, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Eight, Chapter Thirteen, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen, Chapter Nineteen, Chapter Twenty, Chapter Twenty-one, Chapter Twenty-two

If conditionals Chapter Five

If Var In [matchlist] conditional Chapter Sixteen

IfWinActive Introduction, Chapter Two, Chapter Three

Menu Chapter Eight, Chapter Twenty

MouseGetPos Chapter Six

MouseMove Chapter Fifteen

MsgBox Chapter One, Chapter Two, Chapter Four, Chapter Five, Chapter Nine, Chapter Sixteen, Chapter Twenty-one

Return Chapter One, Chapter Two, Chapter Three, Chapter Five

Run Chapter One, Chapter Six

Send Chapter One, Chapter Two, Chapter Six, Chapter Seven, Chapter Nine, Chapter Eleven, Chapter Seventeen, Chapter Eighteen, Chapter Nineteen

Send {Click} Chapter Eleven

SendInput Chapter Eight, Chapter Ten

SetNumLockState Chapter Thirteen

SetTimer Chapter Eight

SoundPlay Chapter Thirteen

SplashImage Chapter Thirteen, Chapter Seventeen

StringSplit Chapter Ten

StringSplit (parsing) Chapter Ten

Ternary operator (single line conditional) Introduction, Chapter Fifteen, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen

Tooltip Introduction, Chapter Fifteen, Chapter Nineteen

WinActivate Chapter Six, Chapter Twenty

WinGet Chapter Four

WinGetClass Chapter Four, Chapter Sixteen

WinMinimize Chapter Four

WinRestore Chapter Four

Commands Versus #Directives Introduction, Chapter Three

ComObjCreate(“SAPI.SpVoice”), speech Chapter Thirteen

Concatenate operator, adds text together Chapter Nine, Chapter Seventeen

Concatenation (combining strings) Chapter Ten

Context-Sensitive Hotkeys Chapter Two

Create multiple Hotkeys for same purpose Chapter Twenty-one, Chapter Twenty-one

CTRL (Control) Key ( ^) Chapter One, Chapter Seven, Chapter Eleven, Chapter Sixteen

Cursor keys for mouse movement Chapter Fifteen

D Hotkey Book

Default shortcuts (buttons) not overridden by Hotkey Chapter Fourteen, Chapter Twenty-one

Deleting words, Hotkeys Chapter Seven

Delimiting (separating) characters Chapter Ten

Directives

#Hotstring Chapter Three

#If expression Chapter Three, Chapter Six, Chapter Fifteen, Chapter Nineteen

#IfWinActive Introduction, Chapter Two, Chapter Three, Chapter Five, Chapter Six, Chapter Thirteen, Chapter Fifteen, Chapter Sixteen

#Include Chapter Three, Chapter Eight

#IncludeAgain Chapter Three

#NoTrayIcon Chapter Three

#Persistent Chapter Three

#SingleInstance off Chapter Three

Documentation, AutoHotkey.com Chapter Twenty-two

Download AutoHotkey Chapter One

E Hotkey Book

Educational scripts Chapter Thirteen

Equal signs, := versus = Chapter Eighteen

ErrorLevel for Hotkey misfires Chapter Nine

ErrorLevel message, Clipboard Chapter Nine, Chapter Ten

F Hotkey Book

Fixing the XButton1 mouse problem Chapter Fourteen, Chapter Twenty-one

Forced expressions (%) Introduction, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen

Forcing expression inside an AutoHotkey command Chapter Seventeen

Functions

RegExReplace() Chapter Ten

SubStr() Chapter Nine, Chapter Ten

WinActive() Chapter Nineteen

WinExist() Chapter Six

Writing Chapter Thirteen

G Hotkey Book

GoSub command Chapter Eight, Chapter Eleven, Chapter Twenty-one

Goto command Chapter Eight

Graphical User Interface (GUI) pop-up Chapter Eight

GroupActivate command Chapter Four

GroupAdd command Introduction, Chapter Four, Chapter Five, Chapter Fifteen, Chapter Sixteen, Chapter Twenty

GUI (Graphical User Interface) command Chapter Eight

GuiClose Label Chapter Eight

GuiControl command Chapter Thirteen

H Hotkey Book

Hidden AutoHotkey.com Index Chapter Twenty-two

Hotkey Best Practice #1 (#IfWinActive Directive) Chapter Fifteen

Hotkey Best Practice #2 (GroupAdd Command) Chapter Fifteen

Hotkey Best Practice #3 (add to System Tray menu) Chapter Twenty

Hotkey command Introduction, Chapter One, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Eight, Chapter Thirteen, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen, Chapter Nineteen, Chapter Twenty, Chapter Twenty-one, Chapter Twenty-two

Hotkey Command Tip Chapter Five

Hotkey Modifiers Chapter One, Chapter Two

ALT (Alternate) Key (!) Chapter One, Chapter Eleven, Chapter Fifteen

Ampersand (&) Chapter Four, Chapter Eleven

Arrow < left and > right Chapter Eleven

CTRL (Control) Key ( ^) Chapter One, Chapter Seven, Chapter Eleven, Chapter Sixteen

SHIFT key (+) Chapter One, Chapter Seven, Chapter Nine, Chapter Ten, Chapter Twelve

Tilde (~) Chapter One

Windows logo key (#) Chapter One, Chapter Two, Chapter Nine, Chapter Twenty-one

Hotkeys Foreword, Introduction, Chapter One, Chapter Two

Add temporary Chapter Sixteen

Hotstring Options

C Case sensitive Chapter Three, Chapter Sixteen

Hotstrings Chapter One

http Chapter Twenty-two

I Hotkey Book

Identical action, multiple Hotkeys Chapter Twenty-one, Chapter Twenty-one

Identifying Active Windows and Programs Chapter Two

Identifying Scan Codes and Virtual Key Codes Chapter Twelve

If conditionals Chapter Five

If Var In [matchlist] conditional Chapter Sixteen

IfWinActive command Introduction, Chapter Two, Chapter Three

Infrequently used keys with a mouse click Chapter Eleven

Install AutoHotkey Chapter One

Irfanview graphics viewer Chapter Fifteen

K Hotkey Book

Key codes

Scan Codes (SCnnn) Foreword, Introduction, Chapter Eleven, Chapter Twelve, Chapter Thirteen, Chapter Fourteen, Chapter Fifteen, Chapter Sixteen, Chapter Seventeen

Virtual Key Codes (VKnnn) Introduction, Chapter Twelve, Chapter Thirteen, Chapter Sixteen

Virtual Key vs Scan Code Chapter Fourteen

Key codes, identifying Chapter Fourteen

Keyboard Hook Chapter Seven

Keyboard, adding back a missing key Chapter Fourteen

Keyboard, using that extra key Chapter Fourteen

Keylist Chapter One, Chapter Eleven, Chapter Twelve, Chapter Fourteen

Keys, NumLock Chapter Eleven, Chapter Thirteen, Chapter Fourteen, Chapter Fifteen, Chapter Sixteen

Keys, assigning both the Virtual Key and Scan Codes Chapter Fourteen

L Hotkey Book

Label subroutine Chapter One, Chapter Five, Chapter Twenty, Chapter Twenty-one

Label, GuiClose Chapter Eight

Line continuation Chapter Four, Chapter Thirteen, Chapter Fifteen, Chapter Sixteen, Chapter Seventeen

Logical Not! operator Chapter Eighteen

Logitech SetPoint mouse software problem Chapter Twenty-one

M Hotkey Book

Menu command Chapter Eight, Chapter Twenty

Menu, System Tray icon (right-click) Introduction, Chapter Twenty

Modifiers, Hotkey Chapter One, Chapter Two, Chapter Eleven

Mouse buttons, XButton Introduction, Chapter Fourteen, Chapter Twenty-one, Chapter Twenty-one, Chapter Twenty-one

Mouse Click Hotkeys Chapter Eleven

Mouse, Send {Click} Chapter Eleven

MouseGetPos command Chapter Six

Mouseless Hotkey Chapter Eleven

MouseMove command Chapter Fifteen

MousePrecise.ahk script Chapter Fifteen, Chapter Sixteen, Chapter Nineteen

MsgBox command Chapter One, Chapter Two, Chapter Four, Chapter Five, Chapter Nine, Chapter Sixteen, Chapter Twenty-one

Multiple Hotkeys, same function Chapter Twenty-one, Chapter Twenty-one

N Hotkey Book

No-Click Volume Control Script Chapter Six

Non-Positional #Directives Chapter Three

NumLock issue, bypass with Scan Codes Chapter Sixteen

NumLock key Chapter Eleven, Chapter Thirteen, Chapter Fourteen, Chapter Fifteen, Chapter Sixteen

O Hotkey Book

Open unopened windows only Chapter Six

P Hotkey Book

Paint.Net image and photo editing Chapter Fifteen

Parse Chapter Ten

Positional #Directives Chapter Three

Precise mouse movement Chapter Fifteen

Problem, fixing an XButton1 mouse button issue Chapter Fourteen, Chapter Twenty-one

Pseudo-array Chapter Ten

Q Hotkey Book

Quick Release Hotkey Chapter Nineteen

R Hotkey Book

Reference tool, AutoHotkey commands Chapter Twenty-two

RegExReplace() Chapter Ten

Regular Expression (RegEx) Chapter Ten

Return command Chapter One, Chapter Two, Chapter Three, Chapter Five

Run command Chapter One, Chapter Six

S Hotkey Book

Same action, multiple Hotkeys Chapter Twenty-one, Chapter Twenty-one

Scan Codes (SCnnn) Foreword, Introduction, Chapter Eleven, Chapter Twelve, Chapter Thirteen, Chapter Fourteen, Chapter Fifteen, Chapter Sixteen, Chapter Seventeen

Secret AutoHotkey.com Index Chapter Twenty-two

Send {Click} Chapter Eleven

Send command Chapter One, Chapter Two, Chapter Six, Chapter Seven, Chapter Nine, Chapter Eleven, Chapter Seventeen, Chapter Eighteen, Chapter Nineteen

SendInput command Chapter Eight, Chapter Ten

SetNumLockState command Chapter Thirteen

SetTimer command Chapter Eight

SHIFT Key Chapter One

SHIFT key (+) Chapter One, Chapter Seven, Chapter Nine, Chapter Ten, Chapter Twelve

SoundPlay command Chapter Thirteen

Speech, ComObjCreate(“SAPI.SpVoice”) Chapter Thirteen

SplashImage Chapter Thirteen, Chapter Seventeen

Standardizing Hotkeys Chapter Seven

StringSplit command (parsing) Chapter Ten

Subroutine, Label Chapter Five, Chapter Twenty, Chapter Twenty-one

SubStr() function Chapter Nine, Chapter Ten

Swapping letters Chapter Nine

Swapping words Chapter Ten

Symbols Chapter One, Chapter Eleven, Chapter Twenty

System Tray Icon Chapter Twenty, Chapter Twenty, Chapter Twenty

System Tray icon menu (right-click) Introduction, Chapter Twenty

T Hotkey Book

Ternary operator (single line conditional) Introduction, Chapter Fifteen, Chapter Sixteen, Chapter Seventeen, Chapter Eighteen

Ternary operator, using functions Chapter Eighteen

Toggle Hotkeys on and off Chapter Eight

Toggling Hotkeys on and off Chapter Eight, Chapter Eighteen

Tooltip command Introduction, Chapter Fifteen, Chapter Nineteen

Tracking the original window Chapter Twenty

V Hotkey Book

Variables

A_Space Chapter Ten

A_ThisHotkey variable Chapter Five

Virtual Key Codes (VKnnn) Introduction, Chapter Twelve, Chapter Thirteen, Chapter Sixteen

Virtual Keys or Scan Codes, which to use Chapter Fourteen

W Hotkey Book

WinActive() function Chapter Nineteen

Window, tracking Chapter Twenty

WindowProbe vs Window Spy Chapter Fifteen

Windows Clipboard Introduction, Chapter Two, Chapter Nine, Chapter Ten

Windows Clipboard techniques Chapter Nine

Windows logo key (#) Chapter One, Chapter Two, Chapter Nine, Chapter Twenty-one

Windows Snipping Tool Chapter Fifteen

Windows Spy Chapter Two, Chapter Two

WinExist() function Chapter Six

WinGet command Chapter Four

WinGetClass command Chapter Four, Chapter Sixteen

WinMinimize command Chapter Four

WinRestore command Chapter Four

WinTitle

ahk_class Chapter Two, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Eight, Chapter Fifteen, Chapter Sixteen

ahk_group Chapter Four, Chapter Five, Chapter Fifteen, Chapter Nineteen

ahk_id Chapter Four, Chapter Six

Writing AutoHotkey Functions Chapter Thirteen

X Hotkey Book

XButton, extra mouse buttons Introduction, Chapter Fourteen, Chapter Twenty-one, Chapter Twenty-one, Chapter Twenty-one

XButton1 mouse problem Chapter Fourteen, Chapter Twenty-one

Beginning Tips for Writing AutoHotkey Scripts

I wrote Beginning Tips for Writing AutoHotkey Scripts not as a tutorial, but as a guide to understanding how AutoHotkey processes scripts and how you can better design applications. For many new AutoHotkey users, the actions AutoHotkey takes when loading a script appear enigmatic causing unpredictable results. While initially many features may not seem to add up, AutoHotkey reads a script in a way that makes total sense—once you comprehend it. You’ll find understanding how AutoHotkey gets things done critical to writing and debugging robust scripts.

Rather than a plethora of programming tips, I offer a framework for viewing AutoHotkey scripts and the script writing process. If you understand everything in this book, then you’ll find writing and debugging AutoHotkey scripts much easier. I include “Best Practices” which make your AutoHotkey life much easier—especially if you plan to later integrate them with other scripts while maintaining their standalone capability. While I include numerous snippets of code in the book, they offer either basic level examples or insight into how AutoHotkey works.

I emphasize the modularity of AutoHotkey throughout the book. That means for the most part you can place encapsulate modules almost anywhere in a script—with a few exceptions. This modularity makes AutoHotkey a very forgiving language, but the exceptions to the rule can be killer.

In Chapter One, I explain how AutoHotkey loads a script in two phases. It reads everything in the first pass but doesn’t take any action until the second pass. I review the key components which might appear in a script and discuss when AutoHotkey interacts with each. You’ll find knowing what happens when in these two passes important to your script design.

Chapter Two takes a close look at how Hotstrings affect a script. Each type of Hotstring acts as a self-contained module which may appear almost anywhere in a script. I explain the three different Hotstring formats—each acting as an encapsulated piece of code.

Similar to the script interaction of Hotstrings, Chapter Three discusses Hotkeys and how to add them to a script. Usually encapsulated, you can place Hotkeys almost anywhere in the script. Examples span from one-liners to adding entire apps to a script with a single Hotkey combination.

Functions provide one of the most flexible methods for adding features to an AutoHotkey script. Especially useful for repetitive tasks, functions allow flexibility in script placement not available to other code snippets. However, to properly implement them, you must understand the difference between local variables and global variables. Chapter Four provides insight into using functions in AutoHotkey scripts.

One of the most common sections of an AutoHotkey script, Label subroutines execute the action. Similar to functions, AutoHotkey accesses these subroutines in a number of different ways. Chapter Five shows methods for directly executing subroutines (Goto and GoSub commands), as well as, Hotkeys set up with the Hotkey command.

A number of other AutoHotkey commands use Label names to initiate subroutines. Chapter Six explains how to launch subroutines with the Menu, SetTimer, OnExit, and GUI (gLabel) commands.

To develop a better understanding of the unique properties of Label names, Chapter Seven drives home the fact that they merely act as signposts in the script—not executable code. I explore unique ways to use Label names to 1) change parameters for a Hotkey one-the-fly; 2) run initial setup routine for the auto-execute section; and 3) create an automatic timeline for a series of steps or instructions (e.g. Jack Stuffed Cheeseburger recipe).

While the online AutoHotkey documentation discourages using the GoTo command, you can put its unique properties to work in certain types of scripts. In Chapter Eight, the unique properties of the GoTo command create a new Jack Stuffed Animal Style Cheeseburger from two parallel recipes.

AutoHotkey Label names offer a unique drop-through behavior which can provide special Hotkey resetting features. In Chapter Nine, I use this Labelname characteristic to reset transparent windows which became impossible to see.

In Chapter Ten and Chapter Eleven, I show you how to write scripts which you can either run as standalone apps or easily combine unchanged with other apps in an omnibus script. I recommend these script designing techniques as best practices for all AutoHotkey apps.

In Chapter Twelve, a question from a reader prompts a demonstration of techniques for converting repetitive subroutines into user-defined functions.

The unusual behavior of #Directives causes a great deal of confusion for the new scriptwriter. Chapter Thirteen explains the difference between AutoHotkey commands and #Directives and shows when to use each.

By the time you reach the end of this book, you should achieve enough of an understanding of how AutoHotkey processes and runs a script, plus the critical component parts found in AutoHotkey scripts, to write robust, easy-to-debug-and-alter applications. The online AutoHotkey documentation—although excellent—does not make it clear how AutoHotkey does its job. This book sheds light on the inner workings and hidden mechanisms of AutoHotkey while showing you how they all work together.

Beginning Tips for Writing AutoHotkey Scripts—Table of Contents

Understanding How AutoHotkey Works and Designing Robust Applications

Fair Use Copyright Notice

Foreword—Beginning Tips for Writing AutoHotkey Scripts

"As a new AutoHotkey scriptwriter, this may be the most important book you can read."

Chapter One: How AutoHotkey Reads Scripts—Beginning Tips for Writing AutoHotkey Scripts

Understanding How AutoHotkey Processes a Script Helps When Writing and Debugging Applications

The Problem with AutoHotkey Script Design

Writing an AutoHotkey Script

The Order of AutoHotkey Scripts

Two Phases of AutoHotkey Script Loading

The Auto-Execute Section of an AutoHotkey Script

Hotstrings

Hotkeys

Functions

Label Subroutines

#Directives

AutoHotkey Commands

The Problem with Combining Multiple AutoHotkey Apps in One Script

Putting It All Together

Chapter Two: Modular Independence of Hotstrings—Beginning Tips for Writing AutoHotkey Scripts

Placement of Powerful Hotstrings for Text Replacement and Text Expansion in AutoHotkey Scripts

Modular Independence

Multi-Line Hotstring Expansion

Hotstring Action Module

View an AutoHotkey Script as a Set of Modules

Chapter Three: Modular Independence of HotKeys—Beginning Tips for Writing AutoHotkey Scripts

Place Versatile Hotkeys for AutoHotkey Apps and Launching Windows Programs Almost Anywhere in an AutoHotkey Script

AutoHotkey HotKeys

Simple One-Line HotKeys

Adding Power to Your Windows Editing with HotKeys

Adding Entire Apps to a Master Script with HotKeys

Chapter Four: Functions as Building Blocks—Beginning Tips for Writing AutoHotkey Scripts

User-Defined Function Format

Calling a Function

Local Versus Global Variables

Making Variables Global

Chapter Five: Enclosed Label Subroutine Building Blocks—Beginning Tips for Writing AutoHotkey Scripts

The Workhorse of AutoHotkey, Label Subroutines Feature the Actions Elements of a Script

AutoHotkey Labels (Subroutines)

Executing Label Subroutines Directly

Methods for Calling Labels (Subroutines)

Chapter Six: Methods for Running Label Subroutines—Beginning Tips for Writing AutoHotkey Scripts

The Menu Command

SetTimer Command

OnExit Command

Using GUI Labels (gLabel)

Chapter Seven: Understanding Label Names and Subroutines—Beginning Tips for Writing AutoHotkey Scripts

Once You Know How AutoHotkey Label Names Work, You Can Add More Tricks to Your Bag of AutoHotkey Skills

AutoHotkey Label Names as Markers

Running Hotkeys with Labels

Turn a Label into a Subroutine

Three Label Name Tricks

Change Parameters for a Hotkey

Run Setup for the Auto-Execute Section

Create a Timeline for a Series of Steps

Original CheeseBurger.ahk Script

Chapter Eight: GoTo Command Versus GoSub Command—Beginning Tips for Writing AutoHotkey Scripts

While the Online Documentation Advises Avoiding the AutoHotkey GoTo Command in Deference to Other AutoHotkey Commands, GoSub, or a User-Defined Function, You’ll Find Times When GoTo Works Best!

Adding Options to the Cheeseburger Recipe

Jack Stuffed Animal Style Cheeseburger

GoTo Versus GoSub

Chapter Nine: Reset Hotkeys with Label Name Drop-Through Behavior—Beginning Tips for Writing AutoHotkey Scripts

Sometimes Not Encapsulating Hotkeys with the Return Command Serves a Purpose

Resetting Parameters by Creating a Drop-through Hotkey

Chapter Ten: Techniques for Merging Standalone AutoHotkey Scripts—Beginning Tips for Writing AutoHotkey Scripts

Encapsulate AutoHotkey Code for Multi-Script Integration and Portability. Run Your AutoHotkey Scripts as Independent Apps or Add Them Unaltered to Master Scripts by Creating Hermetically Sealed Auto-Execute Modules

The Modularity of AutoHotkey

Writing Portable Auto-Execute Sections

Encapsulating Scripts with Label Names

Preventing Conflicts Between Scripts

Variable Name Conflicts

Label Names Conflicts

GUI (Graphical User Interface) Name Conflicts

Function Name Conflicts (Possibly)

Chapter Eleven: How to Write Easy-Merge AutoHotkey Scripts—Beginning Tips for Writing AutoHotkey Scripts

These Steps Make Integrating Your Script Into Combo Apps Simple

Encapsulate the Auto-Execute Section

Create Unique Variable, Label, and Menu Names

Add Names to GUI (Graphical User Interface) Pop-ups

Evaluate Functions

Check for Script-wide AutoHotkey Commands

Final Script Integration

Best Practices

Chapter Twelve: Writing AutoHotkey Functions to Make Life Easier—Beginning Tips for Writing AutoHotkey Scripts

If You Find that You Often Rewrite the Same or Similar Code, Then Investigate Using a Function

A Question about AutoHotkey Functions:

Creating an AutoHotkey Function to Replace Repetitious Code

Assigning Names to the Parameters

Calling the Function

Alternative Method for Calling a Function

Making a Function More Universal

Terminate Your Labels with a Return

Using A_Space

Chapter Thirteen: AutoHotkey Commands Versus #Directives—Beginning Tips for Writing AutoHotkey Scripts

Clearing Up the Confusion between AutoHotkey’s IfWinActive Command and the #IfWinActive Directive

AutoHotkey #Directives

Phase One of AutoHotkey File Processing

Phase Two of AutoHotkey File Processing

Commands Versus #Directives

Positional #Directives

Non-Positional #Directives

Conclusion to Tips for Writing AutoHotkey Scripts

About the Author

Jack Dunning

Index to Beginning Tips for Writing AutoHotkey Scripts

#—Beginning Tips for Writing AutoHotkey Scripts

#Directives Chapter One, Chapter Seven, Chapter Thirteen

#Directives Versus Commands Chapter Thirteen

#Hotstring Chapter Thirteen

#IF directives Chapter One

#If expression directive Chapter Thirteen

#IfWinActive directive Chapter Thirteen

#Include Chapter One, Chapter Two, Chapter Four, Chapter Ten, Chapter Eleven, Chapter Twelve, Chapter Thirteen

#IncludeAgain Chapter Thirteen

#NoTrayIcon Chapter Thirteen

#Persistent directive Chapter Six, Chapter Seven, Chapter Thirteen

#SingleInstance off Chapter Thirteen

%—Beginning Tips for Writing AutoHotkey Scripts

% ternary operator Chapter Seven

^—Beginning Tips for Writing AutoHotkey Scripts

^ CTRL (Control) Key Chapter Three

A—Beginning Tips for Writing AutoHotkey Scripts

A Beginner's Guide to AutoHotkey Author

A_Index built-in variable (Loop) Chapter Eleven

A_Space Chapter Twelve

Action repeated, multiple Hotkeys Chapter Seven

ahk_class Chapter Thirteen

ahk_id Chapter Nine

AutoCorrect app Chapter Two

Auto-execute section of script Chapter One, Chapter Two, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Seven, Chapter Eight, Chapter Ten, Chapter Eleven, Chapter Twelve, Chapter Thirteen

Auto-execute section, encapsulate Chapter Eleven

AutoHotkey Applications E-book Chapter Three, Chapter Six, Chapter Eleven, Author

AutoHotkey books Copyright, Copyright, Copyright, Copyright, Copyright, Copyright, Chapter Three, Chapter Six, Chapter Ten, Chapter Eleven, Author, Author, Author, Author

AutoHotkey file processing Chapter Thirteen

AutoHotkey Functions Chapter Three, Chapter Four, Chapter Five, Chapter Eleven, Chapter Twelve

B—Beginning Tips for Writing AutoHotkey Scripts

Built-in gLabels Chapter Six

C—Beginning Tips for Writing AutoHotkey Scripts

Calling a function Chapter Four, Chapter Twelve

Change parameters for a Hotkey Chapter Seven

CheeseBurgerRecipe.ahk Chapter Seven, Chapter Nine

Clipboard routine Chapter Three

Clipboard, Windows Chapter Three

Commands

ExitApp Chapter Six, Chapter Twelve

FormatTime Chapter Six

GoSub Chapter Six, Chapter Eight, Chapter Nine, Chapter Ten, Chapter Eleven

GoTo Chapter Six, Chapter Eight, Chapter Nine

GUI (Graphical User Interface) Chapter Ten, Chapter Eleven

Gui, Add Chapter Six

Hotkey Chapter One, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Seven, Chapter Eleven, Chapter Thirteen

IfWinActive Chapter Thirteen

IniRead Chapter Twelve

Loop Chapter Ten

Menu Chapter Six

MsgBox Chapter Three, Chapter Six

OnExit Chapter Six

Return Chapter One, Chapter Two, Chapter Three, Chapter Four, Chapter Five, Chapter Seven, Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen

SetTimer Chapter Six

SplashImage Chapter Nine

Ternary operator (single line conditional) Chapter Seven

Commands Versus #Directives Chapter Thirteen

Conflicts

Function name Chapter Ten

Variable name Chapter Ten

Create multiple Hotkeys for same purpose Chapter Seven

CTRL (Control) Key ( ^) Chapter Three

D—Beginning Tips for Writing AutoHotkey Scripts

Design,script Chapter One

Directives

#Hotstring Chapter Thirteen

#If expression Chapter Thirteen

#IfWinActive Chapter Thirteen

#Include Chapter One, Chapter Two, Chapter Four, Chapter Ten, Chapter Eleven, Chapter Twelve, Chapter Thirteen

#IncludeAgain Chapter Thirteen

#NoTrayIcon Chapter Thirteen

#Persistent Chapter Six, Chapter Seven, Chapter Thirteen

#SingleInstance off Chapter Thirteen

Disable a Windows key combination Chapter Three

Download Free AutoHotkey Scripts and Apps Chapter Three

Drop-through behavior, Label name Chapter Nine

E—Beginning Tips for Writing AutoHotkey Scripts

Encapsulate the auto-execute section Chapter Eleven

Encapsulating scripts with Label names Chapter Ten

ExitApp command Chapter Six, Chapter Twelve

F—Beginning Tips for Writing AutoHotkey Scripts

FormatTime command Chapter Four, Chapter Six

Free AutoHotkey Scripts and Apps Chapter Three

Function name conflicts Chapter Ten

Function, calling Chapter Four, Chapter Twelve

Functions, Writing Chapter Three, Chapter Four, Chapter Five, Chapter Eleven, Chapter Twelve

Functions, return a value Chapter Four, Chapter Twelve

Functions, user-defined Chapter Four, Chapter Twelve

G—Beginning Tips for Writing AutoHotkey Scripts

gLabel, subroutine Chapter Six, Chapter Seven

Global variables Chapter Four

GoSub command Chapter Six, Chapter Eight, Chapter Nine, Chapter Ten, Chapter Eleven

GoTo command Chapter Six, Chapter Eight, Chapter Nine

Graphical User Interface (GUI) pop-up Chapter Ten, Chapter Eleven

GUI (Graphical User Interface) command Chapter Ten, Chapter Eleven

GUI Command

Gui, Add Chapter Six

Gui, Add command Chapter Six

GuiClose Label Chapter Eleven, Chapter Twelve

H—Beginning Tips for Writing AutoHotkey Scripts

Hotkey command Chapter One, Chapter Three, Chapter Four, Chapter Five, Chapter Six, Chapter Seven, Chapter Eleven, Chapter Thirteen

HotKey command Chapter Four

Hotkey Modifiers, CTRL (Control) Key ( ^) Chapter Three

Hotkeys Chapter One, Chapter Thirteen

Hotkeys as Label names Chapter Seven

Hotstings Chapter Two

Hotstring

Replacement Chapter Two

Text expansion Chapter One, Chapter Two

Hotstring action module Chapter Two

Hotstring, multi-line expansion Chapter Two

Hotstrings Chapter One

I—Beginning Tips for Writing AutoHotkey Scripts

Identical action, multiple Hotkeys Chapter Seven

IF conditionals Chapter One

IF directives (#) Chapter One

IfWinActive command Chapter Thirteen

Images of AutoHotkey GUI Control Popup Windows Chapter Six

IniRead command Chapter Twelve

L—Beginning Tips for Writing AutoHotkey Scripts

Label name drop-through behavior Chapter Nine

Label name, Hotkey Chapter Seven

Label subroutine Chapter One, Chapter Four, Chapter Five, Chapter Six, Chapter Ten

Label, GuiClose Chapter Eleven, Chapter Twelve

Line continuation Chapter Eleven

Loading phase one, optimization Chapter One, Chapter Thirteen

Local variables Chapter Four

Local versus global variables Chapter Four

Loop command Chapter Ten

M—Beginning Tips for Writing AutoHotkey Scripts

Menu command Chapter Six

Merging AutoHotkey scripts Chapter One, Chapter Ten, Chapter Eleven

MsgBox command Chapter Three, Chapter Four, Chapter Six

Multi-line hotstring expansion Chapter Two

Multiple Hotkeys, same function Chapter Seven

N—Beginning Tips for Writing AutoHotkey Scripts

Non-Positional #Directives Chapter Thirteen

O—Beginning Tips for Writing AutoHotkey Scripts

One-line HotKeys Chapter Three

OnExit command Chapter Six

Optimization phase of script loading Chapter One, Chapter Thirteen

P—Beginning Tips for Writing AutoHotkey Scripts

Parse Chapter One

Passes through the loading script, two phases Chapter One

Portable auto-execute sections Chapter Ten

Positional #Directives Chapter Thirteen

Q—Beginning Tips for Writing AutoHotkey Scripts

QuickLinks.ahk script Chapter Ten

R—Beginning Tips for Writing AutoHotkey Scripts

Return a value to a called functions Chapter Four, Chapter Twelve

Return command Chapter One, Chapter Two, Chapter Three, Chapter Four, Chapter Five, Chapter Seven, Chapter Nine, Chapter Ten, Chapter Eleven, Chapter Thirteen

S—Beginning Tips for Writing AutoHotkey Scripts

Same action, multiple Hotkeys Chapter Seven

ScreenDimmer.ahk script Chapter Ten, Chapter Eleven

Script Design Chapter One

Script loading, two phases Chapter One

Script order Chapter One

SetTimer command Chapter Six

SplashImage Chapter Nine

subroutine, gLabel Chapter Six, Chapter Seven

Subroutine, Label Chapter One, Chapter Four, Chapter Five, Chapter Six, Chapter Ten

System Tray Icon Chapter Seven

T—Beginning Tips for Writing AutoHotkey Scripts

Ternary operator (%) Chapter Seven

Ternary operator (single line conditional) Chapter Seven

U—Beginning Tips for Writing AutoHotkey Scripts

Use and Images of AutoHotkey GUI Control Popup Windows Chapter Six

User-defined functions Chapter Four, Chapter Twelve

V—Beginning Tips for Writing AutoHotkey Scripts

Variable name conflicts Chapter Ten

Variables

A_Space Chapter Twelve

Variables Built-in

A_Index (Loop) Chapter Eleven

Variables, global Chapter Four

Variables, local Chapter Four

W—Beginning Tips for Writing AutoHotkey Scripts

Windows Clipboard Chapter Three

WinTitle

ahk_class Chapter Thirteen

ahk_id Chapter Nine

Writing AutoHotkey Functions Chapter Three, Chapter Four, Chapter Five, Chapter Eleven, Chapter Twelve

Library Members! How to Get Your Discount!

Table of Contents      Beginning Hotstrings Index

Jack's Motley Assortment  of AutoHotkey  Tips

A Living Book

This first edition of Jack's Motley Assortment of AutoHotkey Tips includes more than 80 chapters of AutoHotkey tips, tricks, and techniques. But, that only reflects the starting point for this Living book. Every six months to a year, I will add 30 or more new chapters based upon my current explorations of AutoHotkey. If you own this book, you will get all of these new editions free. You only need to buy this book once.

How to Get Your ComputorEdge AutoHotkey Library Discount forJack's Motley Assortment of AutoHotkey Tips

1. If you're new to the AutoHotkey Library you can either purchase the Motley Plus Mega Bundle which includes all nine of Jack's other AutoHotkey books, plus, Jack's Motley Assortment of AutoHotkey Tips.

2. If you prefer to purchase either the AutoHotkey Starter Bundle or AutoHotkey Intermediate Bundle, you can add on Jack's Motley Assortment of AutoHotkey Tips at a greatly reduced price by entering the discount code "MOTLEY" at check out. (To get the discount, add Jack's Motley Assortment of AutoHotkey TipsThree-Format Bundle which includes all three e-book formats—EPUB, MOBI, and PDF for printing—to your shopping cart. Individual e-book formats will not register the discount.)

3. If you're a current AutoHotkey Library owner, contact us through the Contact Form at Jack's AutoHotkey Blog with your invoice number and/or e-mail address. We will send you a special one-time use discount code for the Jack's Motley Assortment of AutoHotkey Tips Bundle (all three formats). Add the bundle to your shopping cart and use the code at check out to receive your discount.

4. If, in the past, you've purchased any other AutoHotkey books from ComputorEdge E-Books and would like to upgrade to a current AutoHotkey Library Bundle, use the Contact Form at Jack's AutoHotkey Blog with your invoice number(s) and/or e-mail address. We will calculate the value of your previous purchases and send you a one-time discount code toward the purchase of an appropriate bundle. That includes bundle upgrades.

5. Not sure what you want? Contact us and we'll explain your options. Be sure to include any pertinent information.

6. Sorry, but we cannot give any credit for Amazon purchases.

Note: If you bought this book at ComputorEdge E-Books and need additional downloads for the latest version, contact us through the Jack's AutoHotkey Blog contact form. Please supply the invoice number, although, we can look your purchase up based upon your e-mail address.

Miscellaneous AutoHotkey Tips

Jack's Motley Assortment of AutoHotkey Tips contains a wide variety of techniques for both beginning and more advanced users (e.g. Regular Expressions (RegEx) and Web scraping). I've done my best to bring a semblance of order to the chapters and group them into sections based upon common themes. Some appear in order based upon application or type of AutoHotkey techniques (e.g. Clipboard usage, window manipulation). I recommend three methods for searching for specific topics:

1. Scan the "Table of Contents" for specific chapters or topics.

2. Use the alphabetical "Index" at the back of the book to locate topics, commands, or tips. (Check "Tips" in the "Index" for a long narrative type list of the various techniques covered in this book.)

3. Use the search capability in your e-book or PDF software to search for relevant information.

Some topics continue as a work-in-progress (i.e. AutoHotkey Reference Tool). As I update the book, more chapters will appear—adding to the solutions.

To determine if you have the most recent version of Jack's Motley Assortment of AutoHotkey Tips, you can check the date of publication, the edition number, or the chapter number within the book. Whenever I release a new version, I will change the first two at the ComputorEdge E-Books site. Within the book, I plan to use new numbers for new chapters. For example, in the first edition every chapter uses the digit 1 as the second part of the number (e.g. "3.1.4 Blocking Mouse Action"). When I add chapters to the next edition, I plan to use the digit 2 as the second part of the number (e.g. "3.2.6 Special Mouse Considerations"). This number system will make it easier to identify new content in new versions of the book.

Table of Contents

Fair Use Copyright

Foreword

Jack's Motley Assortment of AutoHotkey Tips A Living Book

by Jack Dunning

Miscellaneous AutoHotkey Tips

1.1 Date Tricks Section

A Trick for Inserting Next Friday's Date

An AutoHotkey Technique for Determining Date for a Coming Day of the Week

Turning a Simple Weekday Date Trick into an Easy AutoHotkey Function

If You Need to Do It Over and Over Again, Make It an AutoHotkey Function

1.1.1 A Trick for Inserting Next Friday's Date

An AutoHotkey Technique for Determining Date for a Coming Day of the Week

AutoHotkey Version 2.0 Note For Calculating Dates

1.1.2 Turning a Simple Weekday Date Trick into an Easy AutoHotkey Function

If You Need to Do It Over and Over Again, Make It an AutoHotkey Function

We convert the tip for finding next Friday's date into a function for inserting the date of any upcoming weekday.

Adding the Hotstrings to a Script

A Menu of Multiple Fridays in Multiple Formats

2.1 Clipboard Tricks Section

Peek Inside Windows Clipboard, Part 1 (Beginning AutoHotkey Tip)

A Quick, Easy Way to View Windows Clipboard Contents

Peek Inside Windows Clipboard, Part 2 (Intermediate AutoHotkey OnClipboardChange Tip)

An AutoHotkey OnClipboardChange Script for Running the Most Appropriate of Two Different Clipboard Peeking Apps

2.1.1 Peek Inside Windows Clipboard, Part 1 (Beginning AutoHotkey Tip)

A Quick, Easy Way to View Windows Clipboard Contents

Clipboard and ClipboardAll

Viewing Windows Clipboard Contents

The Easiest Way to See Clipboard Contents

2.1.2 Peek Inside Windows Clipboard, Part 2 (Intermediate AutoHotkey OnClipboardChange Tip)

An AutoHotkey OnClipboardChange Script for Running the Most Appropriate of Two Different Clipboard Peeking Apps

Identifying Clipboard Data Type with OnClipboardChange and A_EventInfo

Capturing Clipboard Data Type

3.1 Mouse Tricks Section

Changing Mouse Cursor Speed with AutoHotkey API Calls

Slowing Down Mouse Cursor Movement with DllCall()

A Look at the AutoHotkey DllCall() Function

Window Mouse Transparency Wheel

Handy Window Transparency Wheel Using Macro Replacement Quickly Peeks Under a Window without Moving It, Plus the Difference Between % Var and %Var% Made Easy

Mouse Transparency Wheel: Reset Hotkeys with Label Name Drop-Through Behavior

Sometimes Not Encapsulating Hotkeys with the Return Command Serves a Purpose

Blocking Mouse Action

Clarification of Other AutoHotkey BlockInput Command Tips

3.1.1 Changing Mouse Cursor Speed with AutoHotkey API Calls

Using DllCall() Functions in AutoHotkey Scripts

Using Mysterious Windows Tools

Slowing Down Mouse Cursor Movement with DllCall()

Understanding the AutoHotkey DllCall() Function

Slowing Down the Mouse Cursor Speed

Restoring the Original Value

3.1.2 Window Mouse Transparency Wheel

Handy Window Transparency Wheel Using Macro Replacement Quickly Peeks Under a Window without Moving It, Plus the Difference Between % Var and %Var% Made Easy

Using the Mouse in Hotkey Combinations

Using Variables Containing Variable Names

Variable Evaluation (% Var) Versus Variable Text Replacement (%Var%)

3.1.3 Transparency Wheel: Reset Hotkeys with Label Name Drop-Through Behavior

Sometimes Not Encapsulating Hotkeys with the Return Command Serves a Purpose

Resetting Parameters by Creating a Drop-through Hotkey

3.1.4 Blocking Mouse Action

Clarification of Earlier AutoHotkey BlockInput Command Tips

BlockInput, Mouse Command

BlockInput, MouseMove Command

No Special Actions Required

4.1 AutoHotkey Menus Section

Windows System Tray Icon Context Menu

Dynamically Switch the Actions of a Running AutoHotkey Script with a Simple Click of a System Tray Right-Click Menu Item

Stuffing More into AutoHotkey Pop-up Menus

Rather Than Increasing the Length of a System Tray Menu, Add Submenus—Plus, How to Use Menu Names (A_ThisMenu) for Conditional Actions, Plus Printing from the System Tray Menu

Eliminate Hotkeys with AutoHotkey Menus

Why Memorize a Bunch of Hotkey Combinations When Using an AutoHotkey Pop-up Menu Does the Trick?

Automatically Add Windows Shortcuts to the QuickLinks App

Rather than Manually Creating Windows Shortcuts for QuickLinks.ahk, Use the AutoHotkey FileCreateShortcut Command

Spice Up AutoHotkey Menus with Icons

Using the Right Images Make Your AutoHotkey Menus Both Prettier and More Useful

Finding Windows Icons for AutoHotkey Menus

A Useful AutoHotkey Script for Quickly Identifying Icons Embedded in Other Windows Files

Add Secret Windows Tools (God Mode) to QuickLinks Menu

This Windows Trick Works in Vista, Windows 7, 8, and 10

Using Unique Icons for Specific Windows Shortcuts

Draw Icons for AutoHotkey Menus Directly from Windows Shortcuts

4.1.1 Windows System Tray Icon Context Menu

Dynamically Switch the Actions of a Running AutoHotkey Script with a Simple Click of a System Tray Right-Click Menu Item

Adding a Toggling Checkmark to a Menu

Tracking the State of a Toggling Checked Menu Item

Alternative Actions

4.1.2 Stuffing More into AutoHotkey Pop-up Menus

Rather Than Increasing the Length of a System Tray Menu, Add Submenus—Plus, How to Use Menu Names (A_ThisMenu) for Conditional Actions

Using Menu Names for Conditional Actions (or How to Print the Right Recipe)

4.1.3 Eliminate Hotkeys with AutoHotkey Menus

Why Memorize a Bunch of Hotkey Combinations When Using an AutoHotkey Pop-up Menu Does the Trick?

Use QuickLinks.ahk to Eliminate Hotkeys

4.1.4 Automatically Add Windows Shortcuts to the QuickLinks App

Rather than Manually Creating Windows Shortcuts for QuickLinks.ahk, Use the AutoHotkey FileCreateShortcut Command

Using QuickLinks to Add Programs (and Menu Items) to QuickLinks

4.1.5 Spice Up AutoHotkey Menus with Icons

Using the Right Images Make Your AutoHotkey Menus Both Prettier and More Useful

Where to Find Icons

Two Types of Windows Shortcuts

Inserting Program Icons into AutoHotkey Menus

Alternative Icons for Other Scripts and Apps

Web Page Targets in Standard Windows Shortcuts (.lnk)

Identifying Shortcuts for Opening Windows Folders (Directories)

Adding Special Icons

4.1.6 Finding Windows Icons for AutoHotkey Menus

A Useful AutoHotkey Script for Quickly Identifying Icons Embedded in Other Windows Files

4.1.7 Add Secret Windows Tools (God Mode) to QuickLinks Menu

This Windows Trick Works in Vista, Windows 7, 8, and 10

Add Windows Tool to QuickLinks or Any Other Menu

4.1.8 Using Unique Icons for Specific Windows Shortcuts (AutoHotkey Menu Tip)

Draw Icons for AutoHotkey Menus Directly from Windows Shortcuts

Code for Inserting Windows Shortcut Icons into Menus

5.1 Window Manipulation with the WinSet Command

Make a Window Transparent Using the WinSet Command (Beginning AutoHotkey Tip)

After Setting a Window to Always-On-Top, Make It See-through for Peeking Underneath

The WinSet, ExStyle Command for Mouse Click-Thru Transparent Windows (Intermediate AutoHotkey Tip)

After Always-On-Top and Translucent Windows, Use the WinSet Command to Make a Mouse-Click Transparent Help Window, Plus a Discussion of the Mysterious (and Confusing) Microsoft Window Styles/ExStyles (WS_XXX and WS_EX_XXX)

WinSet, TransColor Command for Both Transparent and Mouse Click-Thru Windows (Intermediate AutoHotkey Tip)

The WinSet, TransColor Option Offers an Alternative Method for Placing Data and/or Images Onscreen and On Top without Interfering with Your Work

Change Window Shapes Using the WinSet, Region Command (Intermediate AutoHotkey Tip)

Make Odd Shaped Windows with the AutoHotkey WinSet, Region Command, Plus a Script for Creating a Mouse Spotlight

Examine Window Status with WinGet, ExStyle

ExStyle Settings Help to Polish AutoHotkey Window Manipulation Scripts, Plus a Couple More Tricks

5.1.1 Make a Window Transparent Using the WinSet Command (Beginning AutoHotkey Tip)

After Setting a Window to Always-On-Top, Make It See-through for Peeking Underneath

Make Help Windows Easier to Use

Multiple Values for Transparency

5.1.2 The WinSet, ExStyle Command for Mouse Click-Thru Transparent Windows (Intermediate AutoHotkey Tip)

After Always-On-Top and Translucent Windows, Use the WinSet Command to Make a Mouse-Click Transparent Help Window, Plus a Discussion of the Mysterious (and Confusing) Microsoft Window Styles/ExStyles (WS_XXX and WS_EX_XXX)

The WinSet, Style/ExStyle Command

Making a Window Transparent vs. Mouse Click-Thru Transparent

Toggling Mouse-Click Transparency On and Off

Always-On-Top, Transparent, Mouse-Click-Through Help Windows

5.1.3 WinSet, TransColor Command for Both Transparent and Mouse Click-Thru Windows (Intermediate AutoHotkey Tip)

The WinSet, TransColor Option Offers an Alternative Method for Placing Data and/or Images Onscreen and On Top without Interfering with Your Work

5.1.4 Change Window Shapes Using the WinSet, Region Command (Intermediate AutoHotkey Tip)

Make Odd Shaped Windows with the AutoHotkey WinSet, Region Command, Plus a Script for Creating a Mouse Spotlight

A Practical Application? Create a Spotlight by Punching a Hole in a GUI Window Background

5.1.5 Examine Window Status with WinGet, ExStyle

ExStyle Settings Help to Polish AutoHotkey Window Manipulation Scripts, Plus a Couple More Tricks

Always-on-Top Status

Always-on-Top Status with a Couple of AutoHotkey Tricks

6.1 Education Section

Entertaining and Educating Toddlers with a Talking KeyboardToddlers

Turn Your Windows Keyboard into a Learning Experience--Teaching the Alphabet with Animal Sounds

More AutoHotkey Entertainment and Education

Scripts with Tools for Creating Educational Scripts

6.1.1 Entertaining and Educating Toddlers with a Talking Keyboard

Turn Your Windows Keyboard into a Learning Experience--Teaching the Alphabet and Spelling with Animal Sounds

6.1.2 More AutoHotkey Entertainment and Education

Scripts with Tools for Creating Educational Scripts

Make Your Computer Talk to You

The Laughing Cow

Pictures with Sounds

Combining More Pictures and Sounds

Keyboard Hotkey and Hotstring Magic

Another Technique for Making a Keyboard Talk: A Simple One-Line Script to Teach the Computer Keyboard and Alphabet

7.1 AutoHotkey Web Search Section

Make Simple Instant Web Page Searches Your Online Thesaurus

Expand Your Vocabulary with This Quick and Dirty AutoHotkey Tip Or Modify This Script for Any Web Page Search

Learn a Hidden AutoHotkey Trick for Quickly Accessing AutoHotkey Online Command Information

The Problem with Accessing Web Data with AutoHotkey Scripts

The Trouble with Scripts Which Use Web Page Information, Plus AutoHotkey Tools for Downloading Web Page Source Code

AutoHotkey Quick Reference Script

The AutoHotkey.com built-in Index Reappears—Now to Build a Reference Tool!

Regular Expressions (RegEx) for Parsing Text (AutoHotkey Quick Reference Script)

The RegExReplace() Function Makes It Easy to Extract and Cleanup Text, Plus a Quick-and-Dirty RegEx to Strip All HTML Tags

Using INI Files for Web Address (URL) Letter Case-Sensitivity Problems (AutoHotkey Quick Reference Script)

The Wrong Capitalization of Letters in URLs Can Cause Page Access Failure—A Trick for Using an INI File to Solve Case Problems in AutoHotkey

Ryan’s RegEx Tester for Building INI Data Files(AutoHotkey Quick Reference Script)

Sometimes It’s Quicker and Easier to Use Ryan RegEx Tester Rather Than Writing an AutoHotkey Script

Too Much Planning Can Get in the Way of Good Scripting (AutoHotkey Quick Reference)

While Preplanning Script Writing Can Be Useful, Don’t Take It Too Seriously—Sometimes It Only Makes Sense to Rewrite Everything

7.1.1 Make Simple Instant Web Page Searches Your Online Thesaurus

Expand Your Vocabulary with This Quick and Dirty AutoHotkey Tip Or Modify This Script for Any Web Page Search

7.1.2 Build Your Own AutoHotkey Command Reference Tool (An AutoHotkey Secret)

My History with the Secret AutoHotkey Online Documentation Index

Learn a Hidden AutoHotkey Trick for Quickly Accessing AutoHotkey Online Command Information

AutoHotkey.com Documentation

AutoHotkey Reference Script for AutoHotkey Commands, Variables, and Documentation

7.1.3 The Problem with Accessing Web Data with AutoHotkey Scripts

The Trouble with Scripts Using Web Page Information—A Cautionary Tale, Plus AutoHotkey Tools for Downloading Web Page Source Code

Web Sites Change

Tools for Accessing Web Page Data

7.1.4 Using RegEx with Web Page AutoHotkey Quick Reference Script

The AutoHotkey.com built-in Index Reappears—Now to Build a Reference Tool!

Using Regular Expressions (RegEx) in the AutoHotkey Quick Reference Script

7.1.5 Regular Expressions (RegEx) for Parsing Text (AutoHotkey Quick Reference Script)

The RegExReplace() Function Makes It Easy to Extract and Cleanup Text, Plus a Quick-and-Dirty RegEx to Strip All HTML Tags

The Universal “Blah, Blah, Blah” RegEx (.+? or .*?)

How the “Blah, Blah, Blah” Regex Works

Stripping HTML Tags with the “Blah, Blah, Blah” Regex

A Little Cleanup with StringReplace

More AutoHotkey.com Quick Reference Features

7.1.6 Using INI Files for Web Address (URL) Letter Case-Sensitivity Problems (AutoHotkey Quick Reference Script)

The Wrong Capitalization of Letters in URLs Can Cause Page Access Failure—A Trick for Using an INI File to Solve Case Problems in AutoHotkey

Applications with Letter Case Sensitivity Problems

Case Sensitivity within Web Pages

Changing Letter Case with INI Files

Add More to the INI File

7.1.7 Ryan’s RegEx Tester for Building INI Data Files (AutoHotkey Quick Reference Script)

Sometimes It’s Quicker and Easier to Use Ryan RegEx Tester Rather Than Writing an AutoHotkey Script

Extracting a Data List from Web Page Source Code

How the RegExReplace Works

The Replacement Text

7.1.8 Too Much Planning Can Get in the Way of Good Scripting (AutoHotkey Quick Reference)

While Preplanning Script Writing Can Be Useful, Don’t Take It Too Seriously—Sometimes It Only Makes Sense to Rewrite Everything

Changing the AutoHotkey Quick Reference Script

Strange Results from the AutoHotkey.com Hidden Index

Speeding Up the Script

How It Works

The Advantage to Using an INI Lookup File

More to Come

8.1 Windows Automation Section

Control Windows Programs with AutoHotkey (Windows Paint Automation, Part One)

AutoHotkey Uses Windows Paint to Demonstrate How to Draw and Fill In a Square with AutoHotkey

Use AutoHotkey to Draw a Straight Line (Windows Paint Automation, Part Two)

While You May Never Need to Do This, this AutoHotkey Techniques Apply to Many Other Applications

Make Your Own Drawing Tools with AutoHotkey (Windows Paint Automation, Part Three)

Build Functions With AutoHotkey to Create Controls for Windows Paint (or Any Other Program)

Controlling More Tools with AutoHotkey (Windows Paint Automation, Part Four)

Taking Another Step Toward Building Autohotkey Tools For Controlling Windows Programs

Automatically Locate Buttons in Windows Programs by Color

This Little Known Autohotkey Command Can Scan a Section of a Window or Image for a Specific Color. Use It to Select Colors In Windows Paint

More Windows Program Automation with the WinMenuSelectItem Command…Maybe

Traditional Style Windows Programs May Benefit by Automating with the WinMenuSelectItem Command

8.1.1 Control Windows Programs with AutoHotkey (Windows Paint Automation, Part One)

AutoHotkey Uses Windows Paint to Demonstrate How to Draw and Fill In a Square with AutoHotkey

Discover tips which help you to both automate the drawing of simple objects and control other types of applications with AutoHotkey

Using Keyboard Shortcuts to Navigate a Program

Fill the Square with Color

How It Works

Easier Shortcut Keys

8.1.2 Use AutoHotkey to Draw a Straight Line (Windows Paint Automation, Part Two)

While You May Never Need to Do This, this AutoHotkey Techniques Apply to Many Other Applications

Jack continues investigating using AutoHotkey drawing controls in Windows Paint

Using the Pencil Tool to Draw a Straight Line

Using Loops to Draw Lines

8.1.3 Make Your Own Drawing Tools with AutoHotkey (Windows Paint Automation, Part Three)

Build Functions With AutoHotkey to Create Controls for Windows Paint (or Any Other Program)

Learn how to use the same line drawing code over and over again by putting it in an AutoHotkey function—then draw a line anywhere in Windows Paint of any length at any angle using only one line of code.

Creating the DrawLine Function

8.1.4 Controlling More Tools with AutoHotkey (Windows Paint Automation, Part Four)

Taking Another Step Toward Building Autohotkey Tools For Controlling Windows Programs

Other Windows Paint Tools

Making Squiggles

Speeding Up the Paint Drawing Function

Temporarily Deactivating the Mouse

A Couple More Tools

8.1.5 Automatically Locate Buttons in Windows Programs by Color

This Little Known Autohotkey Command Can Scan a Section of a Window or Image for a Specific Color—Use It to Select Colors In Windows Paint

Finding a Color in a Window with AutoHotkey

The Search Area

Make a Box and Fill It with Red (move to AutomatePaint3)

8.1.6 Quick Fix for Inserting Color Data into the Windows Paint Palette

Auto-Fill Windows Program Data Fields Using RegEx—Plus, Alternative for Pop-up Messages

Awkward Tag-along Window

Inserting Data into Multiple Fields Using Regular Expressions

Using the TrayTip Command for Displaying User Information

8.1.7 Control Windows Program with the WinMenuSelectItem Command…Maybe

Traditional Style Windows Programs May Benefit by Automating with the WinMenuSelectItem Command

Using WinMenuSelectItem

Using Menu Numbers

9.1 Using Regular Expressions (RegEx)

A Perfect Place to Use an AutoHotkey Regular Expression (RegEx in Text Replacement)

Occasionally, You Run into a Search-and-Replace Problem that Cries Out for an AutoHotkey RegEx (Regular Expression). But, Is Learning How to Use Regular Expressions Worth Your Time? You Decide! Here’s a Real Problem and a Beginner’s Mini-Tutorial for Solving It with RegEx

Regular Expressions (RegEx) don't immediately make sense to anyone—especially if you've never used them before. Even if you understand how they work, you may not find it easy to know where to apply them. This chapter offers one search-and-replace situation where a RegEx makes a huge difference and a short description of how the RegEx works. This chapter includes what you might consider a mini introduction to Regular Expressions. RegExReplace () function

Deleting Duplicate Words with AutoHotkey Regular Expressions (RegEx)

When Too Many Identical Chapter Numbers Appear in the E-Book Index, It’s Time for Another AutoHotkey RegEx, Plus, How to Use a Backreference!

Quick and Dirty Complex Text Replacement with Ryan’s RegEx Tester

While Not For Beginning AutoHotkey Script Writers, This Regular Expression (RegEx) Trick Executes Multiple Complex Text Replacements without Even Writing an AutoHotkey Script

9.1.1 A Perfect Place to Use an AutoHotkey Regular Expression (RegEx in Text Replacement)

Occasionally, You Run into a Search-and-Replace Problem that Cries Out for an AutoHotkey RegEx (Regular Expression). But, Is Learning How to Use Regular Expressions Worth Your Time? You Decide! Here’s a Real Problem and a Beginner’s Mini-Tutorial for Solving It with RegEx

The Problem

The AutoHotkey RegExReplace() Code

The "Standard Clipboard Routine"

The AutoHotkey Regular Expression

Ryan's RegEx Tester

How This RegEx Works

Locate a Consistent Text Key to Match

Create a Subpattern/Backreference

Using the \w and \s Symbols

Create a Range […] of Options

Continue Matching with the Plus Sign +

The Dot . Wildcard

Negative RegEx Matching

Greedy RegExs

Using the Expression \d

Are Regular Expressions Worth the Effort and Learning Curve?

9.1.2 Deleting Duplicate Words with AutoHotkey Regular Expressions (RegEx)

When Too Many Identical Chapter Numbers Appear in the E-Book Index, It’s Time for Another AutoHotkey RegEx, Plus, How to Use a Backreference!

Removing Redundant Text

Eliminating Redundant Chapter Names

How the RegEx Works

9.1.3 Quick and Dirty Complex Text Replacement with Ryan’s RegEx Tester

While Not For Beginning AutoHotkey Script Writers, This Regular Expression (RegEx) Trick Executes Multiple Complex Text Replacements without Even Writing an AutoHotkey Script

The RegEx Script

Ryan’s RegEx Tester

Ryan’s RegEx Tester for Immediate Results—Without a Script

The AHK Links Problem

Writing the RegEx

The RegEx Backreference

The RegExReplace() Replacement Text

Ignoring Previously Linked Filenames

Negative Look-ahead Assertions

10.1 AutoHotkey Printing Section

Printing with AutoHotkey Made Simple

While Other Techniques Exist for Printing Directly from AutoHotkey, Make It Easy by Using Print Drivers from Other Programs

Create a Universal MsgBox Print Function with ControlGetText

When Nothing Else Works for Copying Text, Try the ControlGetText Command and Create a Global MsgBox Print Function

10.1.1 Printing with AutoHotkey Made Simple

While Other Techniques Exist for Printing Directly from AutoHotkey, Make It Easy by Using Print Drivers from Other Programs

Using Windows Program Command Line Capabilities

Using Windows Notepad for Printing Text

Printing the Cheeseburger Recipe

Windows Program Switches

Notepad Versus Wordpad for Printing

Printing Graphics Files

Printing More File Formats

Expanding AutoHotkey Print Opportunities

10.1.2 Create a Universal MsgBox Print Function with ControlGetText

When Nothing Else Works for Copying Text, Try the ControlGetText Command and Create a Global MsgBox Print Function

A Print Problem

CTRL+C Fails Inside PrintItem() Functions

11.1 GUI Control and Data File Section

Calorie Counting with AutoHotkey Revisited

The Calorie Counting Script Comes Out of the Drawer for New Features

Creating the Food History List

Using the Daily Food Count File We Construct a Sorted Food List for Future Reference

Packing More Info into Apps with GUI Tabs

The AutoHotkey Tab GUI Control Offers a Powerful Space Saver for Windows Apps

When you find that you are adding so many data and editing fields to your AutoHotkey GUI windows that they turn into large, grotesque forms, then discover the Tab GUI control. Tabs instantly add more space to your apps without needing more screen.

Resizing GUI Windows and Controls with the Calorie Counting Script, Plus Filtering Out Duplicate and Blank ListView Entries

See How to Add One GUI Control to All Tabs, Make GUI Controls Resizeable, and Load the Food List ListView Control While Filtering Data Entries in the CalorieCount.ahk Script

Using the GuiContextMenu Subroutine When Counting Calories

After Adding a Second Tab with a Food List, It's Time to Add a New Right-Click Menu

Variable Types: Text Strings Versus Numbers in AutoHotkey

A Simple Keyboard Mistake Can Cause Functional Problems

11.1.1 Calorie Counting Revisited with AutoHotkey

The Calorie Counting Script Comes Out of the Drawer for New Features

How the Calorie Count App Works

Changes to the Calorie Count App

Modifying the Calorie Count Script

11.1.2 Creating and Sorting the Food History List

Using the Daily Food Count File We Construct a Sorted Food List for Future Reference

How It Works

Using the Sort Command

11.1.3 Packing More Info into Apps with GUI Tabs

The AutoHotkey Tab GUI Control Offers a Powerful Space Saver for Windows Apps

The GUI (Graphic User Interface) Tab Control

GUI Formatting Options Chart

Switching Tabs

Adding Controls to Another Tab

11.1.4 Resizing GUI Windows and Controls with the Calorie Counting Script, Plus Filtering Out Duplicate and Blank ListView Entries

See How to Add One GUI Control to All Tabs, Make GUI Controls Resizeable, and Load the Food List ListView Control While Filtering Data Entries in the CalorieCount.ahk Script

Placing One Control on All Tabs

Automatic Resizing of GUI Controls

Removing Duplicate and Blank Rows from ListView Control

11.1.5 Using the GuiContextMenu Subroutine When Counting Calories

After Adding a Second Tab for a Food List, It's Time to Add a New Right-Click Menu

Adding a New Right-click Menu to the Food List

The GuiContextMenu G-Label

Adding the Data to the Food Editing Fields

11.1.6 Variable Types: Text Strings Versus Numbers in AutoHotkey

A Simple Keyboard Mistake Can Cause Functional Problems

AutoHotkey Numbers Versus Strings

Controlling the Variable Type

12.1 Instant Hotkey GUI and Menu Section

AutoHotkey Solutions for Windows Clipboard Limitations (Temporary Hotkeys)

Sometimes It’s Just Easier To Set Up a Temporary Hotkey for Inserting Text into Documents, Web Pages, or Forms, Plus a Quick Reminder of a Couple of Cool Clipboard-like AutoHotkey Apps (ClipJump and PhraseOMatic)

Create Multiple InstantHotkey GUI Pop-Ups On-the-Fly in a Single Script

This AutoHotkey GUI (Graphical User Interface) Trick Builds New GUIs (Graphical User Interfaces) On-the-Fly Simultaneously in the Same Script without Conflicts

Two-Deep Variables for Tracking Data

When You Find No Obvious Way to Link Specific Data to an Object or Another Value, You Might Try Saving It to a Variable within a Variable

Matching Instant Hotkey Combinations with a Loop

Sometimes You’ll Find a Loop a Simpler Way to Match Things

Using Associative Arrays to Solve the Instant Hotkey Data Recall Problem

While Many Other Approaches Work (Sort of), AutoHotkey Associative Arrays Provides a Simple Solution

The AutoHotkey “For Key [, Value] in Expression” Loop for Associative Arrays

The Standard AutoHotkey Loop Command Works Great for Incremental Series, But the For Key [, Value] in Expression Object Loop Offers Unique Flexibility for Associative Arrays

Turn AutoHotkey System Tray Icons into One-Click Action Buttons

Rather Than Using Hotkey Combinations, a Simple Click of the Icon in the Windows System Tray Launches Your App

12.1.1 AutoHotkey Solutions for Windows Clipboard Limitations (Temporary Hotkeys)

Sometimes It’s Just Easier To Set Up a Temporary Hotkey for Inserting Text into Documents, Web Pages, or Forms, Plus a Quick Reminder of a Couple of Cool Clipboard-like AutoHotkey Apps (ClipJump and PhraseOMatic)

The Text Replacement Problem

Clipboard-like (Only Better) AutoHotkey Apps—First ClipJump

PhraseOMatic

InstantHotkey AutoHotkey Script

A More Permanent Solution

12.1.2 Create Multiple InstantHotkey GUI Pop-Ups On-the-Fly in a Single Script

This AutoHotkey GUI (Graphical User Interface) Trick Builds New GUIs (Graphical User Interfaces) Simultaneously in the Same Script without Conflicts

Running Multiple GUI Pop-ups in the Same Script

12.1.3 Two-Deep Variables for Tracking Data

When You Find No Obvious Way to Link Specific Data to an Object or Another Value, You Might Try Saving It to a Variable within a Variable

Saving Unique Variable Names

Linking the Insertion Text to the Hotkey Combination with a Two-Deep Variable

Creating a Legal Variable Name

12.1.4 Matching Instant Hotkey Combinations with a Loop

Sometimes You’ll Find a Loop a Simpler Way to Match Things

12.1.5 Using Associative Arrays to Solve the Instant Hotkey Data Recall Problem

While Many Other Approaches Work (Sort of), AutoHotkey Associative Arrays Provides a Simple Solution

AutoHotkey Variable Arrays

Pseudo-Arrays

Simple and Associative Arrays

Setting Up True Arrays

Creating Arrays

Saving Instant Hotkey Data

12.1.6 The AutoHotkey “For Key [, Value] in Expression” Loop for Associative Arrays

The Standard AutoHotkey Loop Command Works Great for Incremental Series, But the For Key [, Value] in Expression Object Loop Offers Unique Flexibility for Associative Arrays

The For-loop Command

For-loop Display Order

12.1.7 Turn AutoHotkey System Tray Icons into One-Click Action Buttons

Rather Than Using Hotkey Combinations, a Simple Click of the Icon in the Windows System Tray Launches Your App

The Main Window

13.1 Miscellaneous AutoHotkey Tips Section

Disabling Select Hotstrings to Prevent Replacement Misfires

Every So Often You Slap Yourself on the Side of the Head When You Realized How Simple You Can Make It!

Access Your Hotkeys with Hotstrings

An AutoHotkey Hotstring Secret

Using the Raw Option in Send Commands and Hotstrings

Both Hotkey Modifiers and Special Characters Might Disappear When Used in Regular Text. Usually, You’ll Find the Raw Mode the Easiest Solution for Vanishing Characters.

A Simple One-Line Pop-up Help Window

One Line of Code Builds a Help Window

Optimizing the AutoHotkey Message Box

Use These AutoHotkey MsgBox Tricks for Adding Power and Flexibility to Your Scripts. If You Want a Simple, Quick Way to Display Data and Execute Action, You’ll Love These Techniques!

Automatically Launch Apps at Windows Startup

Discover Autohotkey Tricks By Perusing Code In Other Scripts, Plus How to Load Any Windows Program at Startup

Control, EditPaste for Speed

The Control, EditPaste Command Adds Great Speed to Standard Text Insertion Routines—within Certain Limits

13.1.1 Disabling Select Hotstrings to Prevent Replacement Misfires

Every So Often You Slap Yourself on the Side of the Head When You Realized How Simple You Can Make It!

A Simple Hotstring Fix

13.1.2 Access Your Hotkeys with Hotstrings

An AutoHotkey Hotstring Secret

13.1.3 Using the Raw Option in Send Commands and Hotstrings

Both Hotkey Modifiers and Special Characters Might Disappear When Used in Regular Text. Usually, You’ll Find the Raw Mode the Easiest Solution for Vanishing Characters.

Finding Lost Characters

Two Types of Special Characters

How to Resolve Strange Symbol-Losing Behavior

How to Produce Plain Text with the Raw Option

Sending Raw Data with a Hotstring

When the Raw Option Doesn’t Work

13.1.4 A Simple One-Line Pop-up Help Window

One Line of Code Builds a Help Window

13.1.5 Optimizing the AutoHotkey Message Box

Use These AutoHotkey MsgBox Tricks for Adding Power and Flexibility to Your Scripts. If You Want a Simple, Quick Way to Display Data and Execute Action, You’ll Love These Techniques!

Three-button Message Box

Adding a Fourth Button (Help) to the Message Box

Changing Message Box Button Names

Changing Message Box Button Actions

Reaching MsgBox Limits

13.1.6 Automatically Launch Apps at Windows Startup

Discover Autohotkey Tricks By Perusing Code In Other Scripts, Plus How to Load Any Windows Program at Startup

How to Toggle Automatic Loading of AutoHotkey Scripts

Setup Hotkey to Auto-Startup Any Windows Program

13.1.7 Control, EditPaste for Speed

The Control, EditPaste Command Adds Great Speed to Standard Text Insertion Routines—within Certain Limits

Speeding Up Text Insertion Routines

The Send Command Versus the Control, EditPaste Command

Windows Programs and Edit Controls

Use Control, EditPaste for AutoHotkey GUI Controls

14.1 AutoHotkey Apps Section

Free AutoHotkey Virtual Numeric Keypad App

A Quick Little AutoHotkey App for Small Laptops with No Numeric KeyPad, Plus Always-on-top and Use without Making It Active

EitherMouse for Lefties, the Ambidextrous, and Multiple Monitors

A Clever Little Tool for Using Multiple Mice on the Same Computer, Plus a Peek at Some Advanced AutoHotkey Techniques

Unhide Hidden Files with Windows Registry Setting to Find Lost Data

Toggle Hidden Files, System Files, and File Extensions in the Windows Registry with this AutoHotkey Script

A Quick, Light AutoHotkey Script for Background Music

TinyShuffle, a Free App to Randomly Play Your Favorite Music

A Quick and Dirty Windows Stopwatch

Your Minute Is Up!

Fix Grammar Problems with Google Search and GooglePhraseFix (Intermediate AutoHotkey Tip)

The GooglePhraseFix AutoHotkey Script Corrects Many Common Spelling and Grammar Errors While Demonstrating How to Download Information from the Web…without Opening a Browser

The Free AutoHotkey TypingAid App Adds Word Choice to All Windows Programs

Add Word Recommendation Pop-ups to Your Programs

An AutoHotkey Speed Reading App

Who Doesn't Want to Read Faster?

14.1.1 Free AutoHotkey Virtual Numeric Keypad App

A Quick Little AutoHotkey App for Small Laptops with No Numeric KeyPad, Plus Always-on-top and Use without Making It Active

Mouse Click-able, Yet Remains Inactive

Transparent GUI

14.1.2 EitherMouse for Lefties, the Ambidextrous, Multiple Monitors or Multiple Mice

A Clever Little Tool for Using Multiple Mice on the Same Computer, Plus a Peek at Some Advanced AutoHotkey Techniques

EitherMouse for Lefties and Two Mice

Add a Second Cursor

EitherMouse.ahk for AutoHotkey Scripters

Use a GUI Window for the System Tray Right-click Menu

Where Are All the Icons?

14.1.3 Unhide Hidden Files with Windows Registry Setting to Find Lost Data

Toggle Hidden Files, System Files, and File Extensions in the Windows Registry with this AutoHotkey Script

Hiding Secret Files

Working with the Windows Registry

The RegRead and RegWrite Commands

14.1.4 A Quick, Light AutoHotkey Script for Background Music

TinyShuffle, a Free App to Randomly Play Your Favorite Music

How TinyShuffle Works

Randomizing Your AutoHotkey Output

14.1.5 A Quick and Dirty Windows Stopwatch

Your Minute Is Up!

14.1.6 Fix Grammar Problems with Google Search and GooglePhraseFix (Intermediate AutoHotkey Tip)

The GooglePhraseFix AutoHotkey Script Corrects Many Common Spelling and Grammar Errors While Demonstrating How to Download Information from the Web…without Opening a Browser

Key Features of GooglePhraseFix

Regular Expressions for Locating IPs

The UrlDownloadToFile Command for Accessing the Web

14.1.7 A Cool Little App for Inputting Common Phrases

PhraseOMatic for When Hotstrings and Hotkeys Just Aren't Good Enough

Changing a Hotkey to Special Mouse Button

The Latest Version of PhraseOMatic

The PhraseOMatic Script

14.1.8 The Free AutoHotkey TypingAid App Adds Word Choice to All Windows Programs

Add Word Recommendation Pop-ups to Your Programs

14.1.9 An AutoHotkey Speed Reading App

Who Doesn't Want to Read Faster?

How SpeedReader Works

Isolate Hotkey Combinations to Specific Windows

15.1 AutoHotkey Tools Section

A Gadget to Check CPU Power Usage (Dynamic AutoHotkey Charts)

Real-Time CPU Power Graph and AutoHotkey Chart Tools

The Main Window for Debugging AutoHotkey Scripts

How to View the Inner Workings and Hidden Mechanisms of Running AutoHotkey Scripts

Writing AutoHotkey Code Fast with SmartGUI Creator (Part 1)

A Powertool for Fast Design and Code Writing for Pop-up Windows

The Easy Way to Build AutoHotkey GUI Windows (SmartGUI Creator, Part 2)

How to Steal GUI Code from Any AutoHotkey Window, Plus More SmartGUI Creator Features

15.1.1 A Gadget to Check CPU Power Usage (Dynamic AutoHotkey Charts)

Real-Time CPU Power Graph and AutoHotkey Chart Tools

Bar Charts in AutoHotkey

15.1.2 The Main Window for Debugging AutoHotkey Scripts

How to View the Inner Workings and Hidden Mechanisms of Running AutoHotkey Scripts

ListLines Main Window Command

ListVars Main Window Command

ListHotkeys Main Window Command

KeyHistory Main Window Command

15.1.3 Writing AutoHotkey Code Fast with SmartGUI Creator (Part 1)

A Powertool for Fast Design and Code Writing for Pop-up Windows

While it's great to build pop-up windows with the AutoHotkey GUI command, writing all that code gets tedious. Use SmartGUI Creator to quickly generate lines for your scripts.

Using SmartGUI Creator

15.1.4 The Easy Way to Build AutoHotkey GUI Windows (Part 2)

How to Steal GUI Code from Any AutoHotkey Window, Plus More SmartGUI Creator Features

Save time by quickly cloning the code from any active AutoHotkey window, plus, more useful SmartGUI Creator techniques.

Stealing GUI Layouts from AutoHotkey Windows

Micro-Positioning GUI Controls with SmartGUI Creator

Adding AutoHotkey Labels (Subroutine) Names

Adding Options to GUI Controls

Move Group in SmartGUI Creator

16.1 Special Tips and Errors

Possible Solution for Failing Hotkeys

An Important Tip for Any AutoHotkey User

Don't Overlook the ErrorLevel Variable When Writing AutoHotkey Scripts

Make Your AutoHotkey Scripts More Robust by Using ErrorLevel

Counting Commas with AutoHotkey

A Quick AutoHotkey Tip for Counting Occurrences of Characters in a Text String

16.1.1 Possible Solution for Failing Hotkeys

An Important Tip for Any AutoHotkey User

SendMode Input Update

16.1.2 Don't Overlook the ErrorLevel Variable When Writing AutoHotkey Scripts

Make Your AutoHotkey Scripts More Robust by Using ErrorLevel

ErrorLevel in AutoHotkey

16.1.3 Counting Commas with AutoHotkey

A Quick AutoHotkey Tip for Counting Occurrences of Characters in a Text String

Using RegExReplace() to Count Commas

16.1.4 Stop Accidental Deletions with the BlockInput Command

Ever Wonder Why You Might Want to Block Keyboard and Mouse Input? Here’s One Reason to Use the BlockInput AutoHotkey Command, Plus the Associated Problems

The BlockInput Command

Run As Administrator

Windows Task Scheduler to Elevate Script Privileges

Running Scheduled Task On Demand with a Windows Shortcut

Another BlockInput Problem

16.1.5 Stop Sticky Keys Caused by the BlockInput Command

AutoHotkey BlockInput Command May Cause Keys to Get Stuck in the Down Position! Fix It with the KeyWait Command

Alternative Use for KeyWait—Pausing the Script

Index to Jack's Motley

Assortment of AutoHotkey Tips

! — Motley AutoHotkey Tips

! ALT (Alternate) Key - 8.1.1 Shortcuts Automate Paint1 1, 2, 3, 4, 5, 6, - 8.1.2 Mouse Control Automate Paint2 7

" — Motley AutoHotkey Tips

"", Double double-quotes (“”), escape character - 7.1.5 Web RegEx Parse AHK Ref3 1

# — Motley AutoHotkey Tips

#IfWinActive directive - 14.1 AHK Apps Section 1, - 14.1.9 App-SpeedReader 2

#Include - 5.1.1 WinSet Transparent 1, - 8.1.3 Build Tools Automate Paint3 2, - 15.1.1 Graph Tools CPU 3

#InstallKeybdHook - 6.1.2 Pictures Sound 1, 2, 3, 4, 5, - 15.1.2 Main Window Debugging 6, - 16.1.1 Failing Hotkeys 7, - 16.1.5 BlockInput Problem 2 8

#NoTrayIcon - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

#SingleInstance off - 12.1.1 Temporary Hotkeys 1

#SingleInstance Off directive - 12.1 GUI Menu Instant Hotkey Section 1, 2, - 12.1.2 Multi-GUI Scripts 3

% — Motley AutoHotkey Tips

% Force an expression (operator) - 3.1.2 Window Transparency Wheel 1, 2, 3, 4, - 5.1 WinSet Command Section 5, - 5.1.5 Window Status WinGet ExStyle 6, 7, 8, 9, - 12.1.3 Two-Deep Variables 10, - 12.1.5 Associative Arrays 11, 12, - 13.1.3 Hotkey-String Raw 13

%var% variable retrieval, traditional method - 3.1.2 Window Transparency Wheel 1, - 12.1.3 Two-Deep Variables 2, - 12.1.5 Associative Arrays 3, 4, 5, - 13.1 Misc AHK Tips Section 6, - 13.1.2 Hotstring Secret 7, - 13.1.3 Hotkey-String Raw 8

& — Motley AutoHotkey Tips

& Ampersand modifier - 7.1.5 Web RegEx Parse AHK Ref3 1, - 8.1.7 WinMenuSelectItem 2

? — Motley AutoHotkey Tips

? : ternary operator (single line conditional) - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2, 3, 4

? Hotstring option - 13.1 Misc AHK Tips Section 1, - 13.1.1 Preventing Hotstring Misfires 2

? Option, activate inside string - 13.1.1 Preventing Hotstring Misfires 1

\ — Motley AutoHotkey Tips

\s symbol (RegEx) - 9.1.1 Using RegEx 1

\w symbol (RegEx) - 9.1.1 Using RegEx 1

^ — Motley AutoHotkey Tips

^ CTRL (Control) Key - 3.1.2 Window Transparency Wheel 1, 2, 3, - 16.1.5 BlockInput Problem 2 4

` — Motley AutoHotkey Tips

`n, new line escape character - 7.1.7 Web RegEx Tester AHK Ref5 1, - 13.1.3 Hotkey-String Raw 2

`r, return escape character - 7.1.7 Web RegEx Tester AHK Ref5 1, - 13.1.3 Hotkey-String Raw 2

{ — Motley AutoHotkey Tips

{Enter} - 3.1.4 Block Mouse 1, - 8.1.1 Shortcuts Automate Paint1 2, 3, 4, 5, - 8.1.2 Mouse Control Automate Paint2 6, 7, 8, - 8.1.3 Build Tools Automate Paint3 9, 10, 11, 12, - 8.1.4 Control Tools Automate Paint4 13, 14, 15, 16, 17, 18, - 8.1.5 Find Colors 19, - 13.1.3 Hotkey-String Raw 20, 21, 22

{Space} - 13.1.3 Hotkey-String Raw 1, 2

+ — Motley AutoHotkey Tips

+ SHIFT key - 1.1.1 Date Trick 1 1, - 1.1.2 Date Trick 2 2, - 15.1.4 SmartGUI Creator23

A — Motley AutoHotkey Tips

A_Desktop built-in variable - 4.1.7 God Mode Menu 1, - 13.1.6 Toggle AutoLaunch 2

A_EventInfo built-in variable - 2.1.2 Clipboard Techniques 2 1, 2, 3, 4, 5, 6, 7, - 11.1.4 Three GUI Techniques 8, - 11.1.5 GuiContextMenu 9, 10, 11, 12

A_EventInfo variable, OnClipboardChange - 2.1 Clipboard Tricks Section 1, 2, 3, - 2.1.2 Clipboard Techniques 2 4, 5, 6, 7, 8, 9, 10, 11

A_Gui, built-in variable - 11.1.4 Three GUI Techniques 1, 2, 3, 4, 5, 6, - 11.1.5 GuiContextMenu 7, 8, 9, 10, 11, 12, 13, - 12.1.3 Two-Deep Variables 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 12.1.4 Matching Loops 25, - 13.1.5 Optimizing MsgBox26

A_GuiWidth, built-in variable - 11.1.4 Three GUI Techniques 1, 2, 3, 4, 5, 6

A_Index built-in variable (Loop) - 6.1.2 Pictures Sound 1, - 11.1.2 Food History and Sorting 2, 3, 4, 5, - 11.1.4 Three GUI Techniques 6, 7, - 11.1.5 GuiContextMenu 8, 9, - 12.1.4 Matching Loops 10, 11, 12, 13, - 13.1.3 Hotkey-String Raw 14

A_Now, built-in variable - 1.1.1 Date Trick 1 1

A_PriorKey built-in variable - 6.1.2 Pictures Sound 1

A_Space - 7.1.8 Tweaking Scripts AHK Ref6 1, 2

A_Startup built-in variable - 4.1.3 Menu Eliminates Hotkeys 1, - 13.1.6 Toggle AutoLaunch 2, 3, 4, 5, 6

A_ThisHotkey built-in variable - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2, 3, - 12.1.4 Matching Loops 4, 5, - 12.1.5 Associative Arrays6, 7, 8, - 13.1.3 Hotkey-String Raw 9

Accessing Web data Problems - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2

Activating ListView controls when switching Tab controls - 11.1.3 Using Gui Tabs1

Active window, Not! Yet click-able virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Add a second cursor to your computer - 14.1.2 App-EitherMouse 1

Add multiple mice - 14.1.2 App-EitherMouse 1

Add secret Windows tools (God Mode) to QuickLinks menu - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2

Adding a fourth button (Help) to the Message Box (MsgBox) - 10.1.2 MsgBox Print ControlGetText 1, - 13.1.5 Optimizing MsgBox 2

Adding controls to another Tab control - 11.1.3 Using Gui Tabs 1

Adding Icons to Menus - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2

Adding Options to GUI Controls SmartGUI Creator - 15.1.4 SmartGUI Creator2 1

Advanced Hotstring techniques - 6.1 Education Section 1, - 6.1.1 Talking Text 2

ahk_id, WinTitle - 3.1 Mouse Tricks Section 1, - 3.1.2 Window Transparency Wheel 2, 3, 4, 5, 6, 7, - 3.1.3 Transparency Wheel Drop-thru 8, - 5.1.2 WinSet Click-thru 9, 10, - 5.1.5 Window Status WinGet ExStyle 11, - 14.1.2 App-EitherMouse 12

Alphabet WAV files - 6.1.1 Talking Text 1

ALT (Alternate) Key ! - 8.1.1 Shortcuts Automate Paint1 1, 2, 3, 4, 5, 6, - 8.1.2 Mouse Control Automate Paint2 7

ALT key to activate internal keyboard shortcuts - 8.1.1 Shortcuts Automate Paint11

AltSubmit Gui option - 11.1.5 GuiContextMenu 1

Always-on-top status - 5.1.5 Window Status WinGet ExStyle 1

Always-on-top virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Always-on-top window - 5.1 WinSet Command Section 1, 2, - 5.1.1 WinSet Transparent 3, - 5.1.2 WinSet Click-thru 4, 5, - 5.1.5 Window Status WinGet ExStyle 6, 7, 8, 9, - 8.1.6 Auto-Insert Color 10, 11

Ampersand (&) modifier - 7.1.5 Web RegEx Parse AHK Ref3 1, - 8.1.7 WinMenuSelectItem 2

AppsKey - 4.1.4 Auto Create Shortcuts 1

Array%index% pseudo-array - 12.1.5 Associative Arrays 1

Array, Associative - 12.1 GUI Menu Instant Hotkey Section 1, 2, 3, 4, - 12.1.3 Two-Deep Variables 5, - 12.1.5 Associative Arrays 6, 7, 8, - 12.1.6 Array For Key Loop9, 10

Arrays, mini-tutorial - 12.1.5 Associative Arrays 1

Arrays, simple - 12.1.5 Associative Arrays 1, 2, 3

Arrays, Simple and Associative Arrays - 12.1.5 Associative Arrays 1

Associative arrays - 12.1 GUI Menu Instant Hotkey Section 1, 2, 3, - 12.1.2 Multi-GUI Scripts 4, - 12.1.3 Two-Deep Variables 5, 6, 7, 8, - 12.1.4 Matching Loops 9, - 12.1.5 Associative Arrays 10, - 12.1.6 Array For Key Loop 11, 12, 13, 14, - 15.1.2 Main Window Debugging 15

Auto-execute section - 4.1.1 Tray Icon Context Menu 1, 2, - 4.1.4 Auto Create Shortcuts 3, - 5.1.1 WinSet Transparent 4, - 10.1.2 MsgBox Print ControlGetText 5, - 12.1.1 Temporary Hotkeys 6

Auto-execute section of script - 4.1.1 Tray Icon Context Menu 1, 2, - 4.1.4 Auto Create Shortcuts 3, 4, - 5.1.1 WinSet Transparent 5, 6, - 10.1.2 MsgBox Print ControlGetText 7, - 12.1.1 Temporary Hotkeys 8, - 12.1.5 Associative Arrays 9, - 14.1.1 App-Keypad 10

AutoHotkey Applications E-book - 4.1.3 Menu Eliminates Hotkeys 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.5 Add Menu Icons 3, - 4.1.8 Shortcut Icons 4, - 6.1.2 Pictures Sound 5, 6, - 7.1.6 Web INI File AHK Ref4 7, - 11.1.1 GUI Controls Calorie Count 8, 9, 10, - 11.1.2 Food History and Sorting 11, - 11.1.3 Using Gui Tabs 12, - 11.1.4 Three GUI Techniques 13, - 11.1.5 GuiContextMenu 14, 15, - 12.1.1 Temporary Hotkeys 16, - 12.1.2 Multi-GUI Scripts 17, - 13.1.5 Optimizing MsgBox18, 19, - 14.1.4 App-TinyShuffleMusic 20, - 15.1.3 SmartGUI Creator1 21, 22, - About the Author 23

AutoHotkey books - 2.1.1 Clipboard Techniques 1 1, 2, - 4.1.3 Menu Eliminates Hotkeys 3, - 4.1.4 Auto Create Shortcuts 4, - 4.1.8 Shortcut Icons 5, - 6.1.2 Pictures Sound 6, 7, - 7.1.2 Secret Index AHK Ref1 8, - 9.1 RegEx Section 9, - 9.1.1 Using RegEx 10, 11, 12, 13, 14, 15, - 9.1.2 Del Dup Words RegEx 16, 17, - 11.1.1 GUI Controls Calorie Count 18, - 11.1.2 Food History and Sorting 19, - 11.1.5 GuiContextMenu 20, - 12.1.1 Temporary Hotkeys 21, - 13.1.5 Optimizing MsgBox22, - 13.1.6 Toggle AutoLaunch 23, 24, - 14.1 AHK Apps Section 25, - 14.1.4 App-TinyShuffleMusic 26, - 14.1.6 App-GooglePhraseFix 27, - 14.1.7 App-PhraseOMatic 28, 29, - 15.1.3 SmartGUI Creator1 30, 31, - 16.1.2 ClipWait ErrorLevel 32, - 16.1.3 Count Char ErrorLevel-RegEx 33, - 16.1.4 BlockInput Problem 1 34, - About the Author 35

AutoHotkey Command Reference Tool - 7.1.2 Secret Index AHK Ref1 1

AutoHotkey Command Reference Tool V1.1 - 7.1.2 Secret Index AHK Ref1 1

AutoHotkey Functions - 1.1 Date Tricks Section 1, 2, - 1.1.2 Date Trick 2 3, 4, - 8.1 Windows Automation Section 5, 6, - 8.1.3 Build Tools Automate Paint3 7, 8, - 8.1.4 Control Tools Automate Paint4 9, - 9.1.1 Using RegEx 10, - 9.1.3 Ryans RegEx Tester 11, - 15.1.1 Graph Tools CPU 12

AutoHotkey Version 2.0

DateDiff() function, V2.0 - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

AutoHotkey Version 2.0

DateAdd() function - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

FormatTime() function - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

Note For Calculating Dates - 1.1.1 Date Trick 1 1

AutoHotkey Version 2.0 examples - 1.1.1 Date Trick 1 1, - 6.1.2 Pictures Sound 2

AutoHotkey.com documentation - 7.1.2 Secret Index AHK Ref1 1

Auto-launch, create shortcut in Startup Folder - 14.1.7 App-PhraseOMatic 1

Automate Web page searches - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Automatically Create Windows Shortcuts - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.5 Add Menu Icons 3

Automatically launch apps at Windows startup - 13.1 Misc AHK Tips Section 1, - 13.1.6 Toggle AutoLaunch 2

Automating programs with built-in shortcuts - 8.1.1 Shortcuts Automate Paint1 1

Automation, Windows Paint - 8.1 Windows Automation Section 1, 2, 3, 4, - 8.1.1 Shortcuts Automate Paint1 5, - 8.1.2 Mouse Control Automate Paint2 6, - 8.1.3 Build Tools Automate Paint3 7, - 8.1.4 Control Tools Automate Paint4 8

Automation, Windows programs - 8.1 Windows Automation Section 1, 2, 3, - 8.1.1 Shortcuts Automate Paint1 4, - 8.1.2 Mouse Control Automate Paint2 5, 6, - 8.1.3 Build Tools Automate Paint3 7

Auto-start scripts - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, - 4.1.4 Auto Create Shortcuts 3

B — Motley AutoHotkey Tips

Backreference, RegEx - 7.1.5 Web RegEx Parse AHK Ref3 1, - 7.1.7 Web RegEx Tester AHK Ref5 2, 3, - 8.1.6 Auto-Insert Color 4, 5, - 9.1.1 Using RegEx 6, 7, 8, 9, 10, 11, 12, - 9.1.2 Del Dup Words RegEx 13, 14, 15, 16, - 9.1.3 Ryans RegEx Tester 17, 18, 19, 20, 21, 22

Backreferences matching repeting data (RegEx) - 9.1.2 Del Dup Words RegEx 1

Binding data with the BoundFunc Object - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

Blocking action, mouse and keyboard - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Blocking Hotstring activation - 13.1 Misc AHK Tips Section 1, - 13.1.1 Preventing Hotstring Misfires 2

BlockInput command - 3.1 Mouse Tricks Section 1, - 3.1.4 Block Mouse 2, - 8.1 Windows Automation Section 3, - 8.1.4 Control Tools Automate Paint4 4, - 16.1.4 BlockInput Problem 1 5, 6, 7, - 16.1.5 BlockInput Problem 2 8

BlockInput command and user privileges - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

BlockInput command, Run As Administrator - 16.1.4 BlockInput Problem 1 1

BlockInput problem, KeyWait command to stop keys stuck down - 16.1.5 BlockInput Problem 2 1

BoundFunc Object - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

Break command (Loop) - 12.1.4 Matching Loops 1

Build your own AutoHotkey command reference tool - 7.1.2 Secret Index AHK Ref1 1

Building INI data files - 7.1.7 Web RegEx Tester AHK Ref5 1

Built-in Labels

GuiContextMenu for adding right-click context menus - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

Button names, changing, MsgBox - 13.1 Misc AHK Tips Section 1, - 13.1.5 Optimizing MsgBox 2, - 14.1.2 App-EitherMouse 3

Buttons, mouse, using extra (XButton1, XButton2) - 14.1.7 App-PhraseOMatic 1

C — Motley AutoHotkey Tips

Calculating Dates, V2.0 - 1.1.1 Date Trick 1 1

Case sensitive Hotstring - 1.1.1 Date Trick 1 1

Case-sensitivity problems in Web Addresses (URL) - 7.1 Web Search Section 1, - 7.1.6 Web INI File AHK Ref4 2

Change window shapes - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2

Change window shapes using the WinSet, Region command - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2

Changing a Hotkey to special mouse button - 14.1.7 App-PhraseOMatic 1

Changing Message Box (MsgBox) button actions - 13.1.5 Optimizing MsgBox 1

Changing Message Box (MsgBox) button names - 13.1.5 Optimizing MsgBox 1

Charting tools in AutoHotkey - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU2

CheeseBurgerRecipe.ahk - 3.1 Mouse Tricks Section 1, - 3.1.3 Transparency Wheel Drop-thru 2, - 10.1.1 AHK Printing Made Simple 3

Click command - 8.1 Windows Automation Section 1, 2, 3, - 8.1.1 Shortcuts Automate Paint1 4, 5, - 8.1.5 Find Colors 6, 7, 8

Click-able, yet never active virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Click-thru transparent windows - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Click-thru window - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

Clipboard Best Practice - 2.1.1 Clipboard Techniques 1 1

Clipboard contents, viewing - 2.1.1 Clipboard Techniques 1 1

Clipboard data type - 2.1.2 Clipboard Techniques 2 1

Clipboard file format - 2.1.1 Clipboard Techniques 1 1, 2

Clipboard variable - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 1 2

Clipboard versus ClipboardAll - 2.1.1 Clipboard Techniques 1 1

Clipboard viewer - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 1 2, 3, 4, - 2.1.2 Clipboard Techniques 2 5, 6

Clipboard viewing techniques - 2.1 Clipboard Tricks Section 1, 2, - 2.1.1 Clipboard Techniques 1 3, - 2.1.2 Clipboard Techniques 2 4

Clipboard, OnClipboardChange subroutine - 2.1 Clipboard Tricks Section 1, 2, 3, - 2.1.2 Clipboard Techniques 2 4, 5, 6, 7, 8, 9, 10, 11

Clipboard, standard routine - 9.1.1 Using RegEx 1

Clipboard, Windows - 2.1 Clipboard Tricks Section 1, 2, 3, 4, 5, 6, - 2.1.1 Clipboard Techniques 1 7, 8, 9, 10, 11, 12, 13, 14, 15, - 2.1.2 Clipboard Techniques 2 16, 17, 18, 19, - 4.1.4 Auto Create Shortcuts 20, - 4.1.6 Finding Icons 21, - 7.1.1 Instant Web Searches 22, 23, - 7.1.4 Web RegEx AHK Ref2 24, - 7.1.8 Tweaking Scripts AHK Ref6 25, - 8.1.6 Auto-Insert Color 26, 27, - 9.1 RegEx Section 28, - 9.1.1 Using RegEx 29, 30, 31, - 9.1.3 Ryans RegEx Tester 32, - 12.1 GUI Menu Instant Hotkey Section 33, - 12.1.1 Temporary Hotkeys 34, 35, 36, 37, 38, 39, 40, - 13.1.2 Hotstring Secret 41, 42, - 13.1.6 Toggle AutoLaunch 43, - 13.1.7 Control EditPaste44, - 14.1.6 App-GooglePhraseFix 45, 46, - 16.1.2 ClipWait ErrorLevel 47, 48, - 16.1.5 BlockInput Problem 2 49

ClipboardAll variable - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 12

Clipboard-like AutoHotkey Apps - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

ClipBook Viewer - 2.1.1 Clipboard Techniques 1 1, 2, 3, 4, 5, 6, - 2.1.2 Clipboard Techniques 2 7, 8, 9, 10

Clipbrd.exe clipboard viewer - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 1 2, 3, 4, - 2.1.2 Clipboard Techniques 2 5, 6

ClipJump Script - 2.1.1 Clipboard Techniques 1 1, 2, - 12.1 GUI Menu Instant Hotkey Section 3, - 12.1.1 Temporary Hotkeys 4, 5, 6, 7, 8, 9, 10, 11, 12, 13

ClipJump, Clipboard-like AutoHotkey Apps - 12.1 GUI Menu Instant Hotkey Section1, - 12.1.1 Temporary Hotkeys 2

ClipWait command - 13.1.6 Toggle AutoLaunch 1, - 16.1 Special Tips and Errors 2, - 16.1.2 ClipWait ErrorLevel 3, 4, 5

Code generator, AutoHotkey SmartGUI Creator - 15.1 AHK Tools Section 1, 2, - 15.1.3 SmartGUI Creator1 3, - 15.1.4 SmartGUI Creator2 4

Color, find with Window Spy utility - 5.1.3 WinSet TransColor 1, - 8.1.1 Shortcuts Automate Paint1 2, - 8.1.5 Find Colors 3, 4, 5, 6, - 10.1.2 MsgBox Print ControlGetText 7, - 13.1.7 Control EditPaste 8, - 15.1.2 Main Window Debugging 9

Color, locate buttons in Windows programs with PixelSearch - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

Coloretta Viva color picking script - 8.1.6 Auto-Insert Color 1, 2

Combining strings, concatenation - 11.1.2 Food History and Sorting 1, - 14.1.6 App-GooglePhraseFix 2, - 15.1.4 SmartGUI Creator2 3

Comma Separated Values (CSV) data files - 11.1.2 Food History and Sorting 1

Command in one-line Hotstring (v1,1,28+) - 6.1 Education Section 1, - 6.1.1 Talking Text 2

Command reference tool, AutoHotkey - 7.1.2 Secret Index AHK Ref1 1

Commands

BlockInput - 3.1 Mouse Tricks Section 1, - 3.1.4 Block Mouse 2, - 8.1 Windows Automation Section 3, - 8.1.4 Control Tools Automate Paint4 4, - 16.1.4 BlockInput Problem 1 5, 6, 7, - 16.1.5 BlockInput Problem 2 8

Break (Loop) - 12.1.4 Matching Loops 1

Click - 8.1 Windows Automation Section 1, 2, 3, - 8.1.1 Shortcuts Automate Paint1 4, 5, - 8.1.5 Find Colors 6, 7, 8

ClipWait - 13.1.6 Toggle AutoLaunch 1, - 16.1 Special Tips and Errors 2, - 16.1.2 ClipWait ErrorLevel 3, 4, 5

ComObjectCreate() function - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

Continue command - 11.1 GUI Control Data File Section 1, - 11.1.2 Food History and Sorting 2

Control, EditPaste - 10.1 AHK Printing Section 1, - 10.1.2 MsgBox Print ControlGetText 2, - 13.1 Misc AHK Tips Section 3, - 13.1.7 Control EditPaste 4

ControlGetText - 10.1 AHK Printing Section 1, - 10.1.2 MsgBox Print ControlGetText 2, 3

ControlSend - 8.1.6 Auto-Insert Color 1, - 13.1.7 Control EditPaste 2, 3

ControlSetText - 13.1.5 Optimizing MsgBox 1

DateTime GUI control - 11.1.1 GUI Controls Calorie Count 1

EnvAdd (+=) - 1.1 Date Tricks Section 1, 2, - 1.1.1 Date Trick 1 3, - 1.1.2 Date Trick 2 4

FileAppend - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 1 2, 3, - 4.1 Menus Section 4, - 4.1.1 Tray Icon Context Menu 5, 6, 7, - 4.1.2 More Tray Menus 8, - 7.1 Web Search Section 9, - 7.1.6 Web INI File AHK Ref4 10, - 10.1 AHK Printing Section 11, - 10.1.1 AHK Printing Made Simple 12, 13, 14, - 10.1.2 MsgBox Print ControlGetText 15, 16, - 16.1.5 BlockInput Problem 2 17

FileCreateDir - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2

FileCreateShortcut - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.5 Add Menu Icons 3, - 13.1 Misc AHK Tips Section 4, - 13.1.6 Toggle AutoLaunch 5

FileInstall - 6.1 Education Section 1, 2, - 6.1.1 Talking Text 3, - 6.1.2 Pictures Sound 4

FileRead - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 1 2, 3, 4, - 7.1 Web Search Section 5, 6, - 7.1.3 Web Search Problems 7, - 7.1.4 Web RegEx AHK Ref2 8, - 7.1.6 Web INI File AHK Ref4 9, 10, - 7.1.8 Tweaking Scripts AHK Ref6 11, 12, - 11.1 GUI Control Data File Section 13, - 11.1.2 Food History and Sorting 14, - 11.1.4 Three GUI Techniques 15, - 14.1.6 App-GooglePhraseFix 16, 17, 18

FileSelectFile - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

For Key [, Value] in Expression (arrays) - 12.1 GUI Menu Instant Hotkey Section 1, 2, 3, - 12.1.6 Array For Key Loop 4, 5, 6

Forced expressions (% operator) - 3.1.2 Window Transparency Wheel 1, 2, 3, 4, - 5.1 WinSet Command Section 5, - 5.1.5 Window Status WinGet ExStyle 6, 7, 8, 9, - 12.1.3 Two-Deep Variables 10, - 12.1.5 Associative Arrays 11, 12, - 13.1.3 Hotkey-String Raw 13

FormatTime - 1.1 Date Tricks Section 1, 2, - 1.1.1 Date Trick 1 3, - 1.1.2 Date Trick 2 4

Global - 10.1.2 MsgBox Print ControlGetText 1

GoSub - 3.1 Mouse Tricks Section 1, - 3.1.3 Transparency Wheel Drop-thru 2

GoTo - 3.1.3 Transparency Wheel Drop-thru 1

GUI (Graphical User Interface) - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2, - 13.1.5 Optimizing MsgBox 3, - 15.1.3 SmartGUI Creator1 4

GUI option, AltSubmit - 11.1.5 GuiContextMenu 1

GUI Tab control - 11.1 GUI Control Data File Section 1, - 11.1.1 GUI Controls Calorie Count 2, - 11.1.2 Food History and Sorting 3, - 11.1.3 Using Gui Tabs 4, 5

Gui, Add - 15.1.3 SmartGUI Creator1 1, 2

Gui, Add, Hotkey - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

Gui, Color command - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Gui, New - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts2

Gui, Tab - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

GuiControl - 11.1.5 GuiContextMenu 1

Hotkey - 3.1.2 Window Transparency Wheel 1, - 4.1.1 Tray Icon Context Menu2, - 4.1.2 More Tray Menus 3, - 4.1.3 Menu Eliminates Hotkeys 4, - 4.1.5 Add Menu Icons 5, 6, - 4.1.8 Shortcut Icons 7, - 5.1.4 WinSet Region 8, 9, - 5.1.5 Window Status WinGet ExStyle 10, 11, - 7.1.2 Secret Index AHK Ref112, 13, 14, - 7.1.3 Web Search Problems 15, - 7.1.8 Tweaking Scripts AHK Ref6 16, 17, - 8.1.1 Shortcuts Automate Paint1 18, - 8.1.6 Auto-Insert Color19, - 10.1.2 MsgBox Print ControlGetText 20, 21, - 12.1 GUI Menu Instant Hotkey Section 22, - 12.1.1 Temporary Hotkeys 23, - 13.1 Misc AHK Tips Section 24, - 13.1.3 Hotkey-String Raw 25, - 13.1.5 Optimizing MsgBox 26, 27, 28, - 13.1.6 Toggle AutoLaunch 29, - 16.1.2 ClipWait ErrorLevel 30, - 16.1.4 BlockInput Problem 1 31, - 16.1.5 BlockInput Problem 2 32

If conditionals - 12.1.4 Matching Loops 1, - 16.1 Special Tips and Errors 2, - 16.1.2 ClipWait ErrorLevel 3

IfExist - 4.1.4 Auto Create Shortcuts 1, - 7.1.8 Tweaking Scripts AHK Ref6 2

IfInString - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2, - 7.1.4 Web RegEx AHK Ref2 3

IfMsgBox - 13.1.5 Optimizing MsgBox 1

IfNotExist - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2, 3, - 7.1.8 Tweaking Scripts AHK Ref6 4, 5, - 14.1.4 App-TinyShuffleMusic 6

IfWinActive - 10.1.2 MsgBox Print ControlGetText 1

ImageSearch command - 8.1.5 Find Colors 1

IniRead - 6.1.2 Pictures Sound 1, - 7.1.6 Web INI File AHK Ref4 2

Input - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, - 1.1.2 Date Trick 2 3, - 3.1 Mouse Tricks Section 4, - 3.1.4 Block Mouse 5, - 8.1 Windows Automation Section 6, 7, 8, - 8.1.1 Shortcuts Automate Paint1 9, - 8.1.4 Control Tools Automate Paint4 10, - 8.1.5 Find Colors 11, - 8.1.6 Auto-Insert Color 12, - 12.1.4 Matching Loops 13, - 12.1.5 Associative Arrays 14, - 13.1.3 Hotkey-String Raw 15, - 13.1.5 Optimizing MsgBox 16, - 16.1.4 BlockInput Problem 1 17, 18, 19, - 16.1.5 BlockInput Problem 2 20

KeyHistory (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

KeyWait - 16.1.5 BlockInput Problem 2 1

ListHotkeys (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

ListLines (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

ListVars (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

ListView GUI control - 11.1.1 GUI Controls Calorie Count 1

Loop - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 8.1 Windows Automation Section 3, - 8.1.2 Mouse Control Automate Paint2 4, - 9.1 RegEx Section 5, - 12.1 GUI Menu Instant Hotkey Section 6, 7, - 12.1.4 Matching Loops 8, - 12.1.5 Associative Arrays 9, - 12.1.6 Array For Key Loop 10

Loop, Parse - 11.1 GUI Control Data File Section 1, - 11.1.2 Food History and Sorting 2

Menu - 1.1.2 Date Trick 2 1, - 4.1 Menus Section 2, 3, - 4.1.1 Tray Icon Context Menu 4, - 4.1.2 More Tray Menus 5, 6, - 4.1.3 Menu Eliminates Hotkeys 7, 8, - 4.1.5 Add Menu Icons 9, - 5.1.1 WinSet Transparent 10, - 12.1.7 One-click Tray Icons 11, - 13.1.6 Toggle AutoLaunch 12

Menu, Tray, Click - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Menu, Tray, Default - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Menu, Tray, NoIcon command (remove icon) - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

Menu, Tray, Tip - 8.1.6 Auto-Insert Color 1, 2

MouseClick - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint1 2

MouseClickDrag - 3.1 Mouse Tricks Section 1, - 3.1.4 Block Mouse 2

MouseGetPos - 3.1 Mouse Tricks Section 1, - 3.1.2 Window Transparency Wheel 2, - 6.1 Education Section 3, - 6.1.1 Talking Text 4

MouseMove - 8.1 Windows Automation Section 1, 2, - 8.1.1 Shortcuts Automate Paint1 3, - 8.1.2 Mouse Control Automate Paint2 4

MsgBox - 2.1.1 Clipboard Techniques 1 1, - 2.1.2 Clipboard Techniques 2 2, - 4.1.1 Tray Icon Context Menu 3, - 7.1 Web Search Section 4, - 7.1.5 Web RegEx Parse AHK Ref3 5, - 7.1.8 Tweaking Scripts AHK Ref6 6, - 8.1.6 Auto-Insert Color 7, - 12.1.6 Array For Key Loop 8, - 13.1.4 Help Pop-up 9, - 13.1.5 Optimizing MsgBox 10, 11, 12

OnClipboardChange - 2.1 Clipboard Tricks Section 1, 2, 3, - 2.1.2 Clipboard Techniques 2 4, 5, 6, 7, 8, 9, 10, 11

PixelGetColor - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

PixelSearch - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

Random - 14.1 AHK Apps Section 1, - 14.1.4 App-TinyShuffleMusic 2

RegRead (Windows Registry) - 14.1.2 App-EitherMouse 1, - 14.1.3 App-UnHideFiles 2, - 14.1.7 App-PhraseOMatic 3

RegWrite (Windows Registry) - 14.1.2 App-EitherMouse 1, - 14.1.3 App-UnHideFiles 2, - 14.1.7 App-PhraseOMatic 3

Reload - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2

Return - 3.1.3 Transparency Wheel Drop-thru 1, - 4.1.1 Tray Icon Context Menu 2

Run - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2, - 10.1 AHK Printing Section 3, - 10.1.1 AHK Printing Made Simple 4, 5, - 12.1.1 Temporary Hotkeys 6, - 12.1.2 Multi-GUI Scripts 7, - 16.1.4 BlockInput Problem 1 8

Send - 7.1.6 Web INI File AHK Ref4 1, - 8.1.6 Auto-Insert Color 2, - 13.1 Misc AHK Tips Section 3, - 13.1.3 Hotkey-String Raw 4, 5, 6, - 13.1.7 Control EditPaste 7, 8, 9

SendInput - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, - 8.1 Windows Automation Section 3, 4, - 8.1.1 Shortcuts Automate Paint1 5, - 8.1.5 Find Colors 6, - 8.1.6 Auto-Insert Color 7, - 12.1.4 Matching Loops 8, - 12.1.5 Associative Arrays 9, - 13.1.3 Hotkey-String Raw 10

SendMessage - 14.1.2 App-EitherMouse 1

SendMode (problem?) - 16.1 Special Tips and Errors 1, - 16.1.1 Failing Hotkeys 2

SetKeyDelay - 13.1.7 Control EditPaste 1

SetTimer - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2, - 13.1.4 Help Pop-up 3, - 13.1.5 Optimizing MsgBox 4, - 14.1 AHK Apps Section 5, 6, - 14.1.2 App-EitherMouse 7, - 14.1.5 App-StopWatch 8, - 14.1.9 App-SpeedReader 9

Sleep - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint12

Sort - 11.1 GUI Control Data File Section 1, - 11.1.2 Food History and Sorting2, 3

SoundPlay - 6.1 Education Section 1, 2, - 6.1.1 Talking Text 3, - 14.1 AHK Apps Section 4, - 14.1.4 App-TinyShuffleMusic 5

SplashImage - 3.1 Mouse Tricks Section 1, - 3.1.2 Window Transparency Wheel 2, - 6.1 Education Section 3, 4, - 6.1.1 Talking Text 5, - 8.1.6 Auto-Insert Color 6

SplashText - 8.1.6 Auto-Insert Color 1, - 16.1.5 BlockInput Problem 2 2

SplitPath - 4.1.4 Auto Create Shortcuts 1, - 13.1 Misc AHK Tips Section 2, - 13.1.6 Toggle AutoLaunch 3

StringReplace - 7.1 Web Search Section 1, - 7.1.5 Web RegEx Parse AHK Ref3 2, - 11.1.6 Variable Type Error 3, - 16.1 Special Tips and Errors 4, - 16.1.3 Count Char ErrorLevel-RegEx 5

StringSplit (parsing) - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

Ternary operator (? : single line conditional) - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2, 3, 4

Tooltip - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2

UpDown GUI control - 11.1.6 Variable Type Error 1

URLDownloadToFile - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2

WinClose - 13.1.5 Optimizing MsgBox 1

WinGet - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4, - 12.1.3 Two-Deep Variables 5

WinMenuSelectItem - 8.1 Windows Automation Section 1, - 8.1.7 WinMenuSelectItem 2

WinSet - 5.1 WinSet Command Section 1, - 5.1.1 WinSet Transparent 2, - 5.1.2 WinSet Click-thru 3, 4

WinSet, ExStyle - 5.1 WinSet Command Section 1, 2, 3, - 5.1.2 WinSet Click-thru 4, 5, 6, 7, 8, 9, 10, 11, 12, - 5.1.5 Window Status WinGet ExStyle 13

WinSet, Region - 5.1 WinSet Command Section 1, 2, - 5.1.4 WinSet Region 3, 4

WinSet, Style - 5.1 WinSet Command Section 1, - 5.1.2 WinSet Click-thru 2, 3, 4, 5, 6, 7, 8

WinSet, TransColor - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

ComObjCreate(“SAPI.SpVoice”), speech - 6.1.2 Pictures Sound 1

ComObjectCreate() function - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

Concatenation (combining strings) - 11.1.2 Food History and Sorting 1, - 14.1.6 App-GooglePhraseFix 2, - 15.1.4 SmartGUI Creator2 3

Continue command - 11.1 GUI Control Data File Section 1, - 11.1.2 Food History and Sorting 2

Continue matching with the plus sign + (RegEx) - 9.1.1 Using RegEx 1

Control Windows programs - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint1 2

Control, EditPaste command - 10.1 AHK Printing Section 1, - 10.1.2 MsgBox Print ControlGetText 2, - 13.1 Misc AHK Tips Section 3, - 13.1.7 Control EditPaste 4

Control, EditPaste for fast text insertion in GUI Edit Controls - 13.1.7 Control EditPaste 1

Control, EditPaste for speed text insertion in EDIT controls - 13.1 Misc AHK Tips Section 1, - 13.1.7 Control EditPaste 2

ControlGetText command - 10.1 AHK Printing Section 1, - 10.1.2 MsgBox Print ControlGetText 2, 3

Controlling the variable type - 11.1.6 Variable Type Error 1

ControlSend command - 8.1.6 Auto-Insert Color 1, - 13.1.7 Control EditPaste 2, 3

ControlSetText command - 13.1.5 Optimizing MsgBox 1

Counting characters with AutoHotkey (ErrorLevel

RegEx) - 9.1 RegEx Section 1, - 16.1 Special Tips and Errors 2, - 16.1.3 Count Char ErrorLevel-RegEx 3

CPU Power Graph - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Create multiple InstantHotkey GUI pop-ups on-the-fly in a single script - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

Create Shortcut in Startup Folder - 14.1.7 App-PhraseOMatic 1

Creating a legal variable name - 12.1.3 Two-Deep Variables 1

Creating Windows Shortcuts (FileCreateShorcut) - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2

CSV (Comma Separated Values) data files - 11.1.2 Food History and Sorting 1

CTRL (Control) Key ( ^) - 3.1.2 Window Transparency Wheel 1, 2, 3, - 16.1.5 BlockInput Problem 2 4

D — Motley AutoHotkey Tips

Data plotting tools - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Date for a coming day of the week - 1.1.1 Date Trick 1 1

Date format, LongDate - 1.1.2 Date Trick 2 1

Date, day-of-week - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, 3, 4, 5, 6, - 1.1.2 Date Trick 2 7, 8, 9, 10

DateAdd() function, V2.0 - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

DateDiff() function, V2.0 - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

DateTime GUI control - 11.1.1 GUI Controls Calorie Count 1

Day-of-week, insert date - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, 3, 4, 5, 6, - 1.1.2 Date Trick 2 7, 8, 9, 10

Deactivating the mouse - 8.1.4 Control Tools Automate Paint4 1

Debugging AutoHotkey scripts, Main Window - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2

Dereferencing variables - 3.1.2 Window Transparency Wheel 1, 2, - 12.1.3 Two-Deep Variables 3

Dereferencing, two-deep variables for tracking data - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2

Directives

#IfWinActive - 14.1 AHK Apps Section 1, - 14.1.9 App-SpeedReader 2

#Include - 5.1.1 WinSet Transparent 1, - 8.1.3 Build Tools Automate Paint3 2, - 15.1.1 Graph Tools CPU 3

#InstallKeybdHook - 6.1.2 Pictures Sound 1, 2, 3, 4, 5, - 15.1.2 Main Window Debugging 6, - 16.1.1 Failing Hotkeys 7, - 16.1.5 BlockInput Problem 2 8

#NoTrayIcon - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

#SingleInstance off - 12.1.1 Temporary Hotkeys 1

#SingleInstance Off directive - 12.1 GUI Menu Instant Hotkey Section 1, 2, - 12.1.2 Multi-GUI Scripts 3

Display order of For Key [, Value] in Expression (arrays) - 12.1.6 Array For Key Loop 1

Dll, Dynamic-Link Library - 3.1.1 Changing Mouse Cursor Speed 1

DllCall() function - 2.1 Clipboard Tricks Section 1, - 2.1.2 Clipboard Techniques 2 2, - 3.1.1 Changing Mouse Cursor Speed 3, - 14.1.2 App-EitherMouse 4

Documentation, AutoHotkey.com - 7.1.2 Secret Index AHK Ref1 1

Double double-quotes (“”), escape character - 7.1.5 Web RegEx Parse AHK Ref3 1

Download

Free AutoHotkey Scripts and Apps - 1.1.1 Date Trick 1 1, - 9.1 RegEx Section 2, - 9.1.3 Ryans RegEx Tester 3, - 12.1.1 Temporary Hotkeys 4

Download site - 9.1.1 Using RegEx 1, - 11.1.1 GUI Controls Calorie Count 2, - 12.1.1 Temporary Hotkeys 3, - 14.1.1 App-Keypad 4, - 14.1.9 App-SpeedReader 5, - 15.1.3 SmartGUI Creator1 6, - 15.1.4 SmartGUI Creator2 7, 8

Download Web page source code - 14.1 AHK Apps Section 1, - 14.1.6 App-GooglePhraseFix 2

Draw square in Windows Paint - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint1 2

Drawing graphs in AutoHotkey - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Drop-through behavior, Label name - 3.1 Mouse Tricks Section 1, - 3.1.3 Transparency Wheel Drop-thru 2

Drop-through Hotkeys - 3.1.3 Transparency Wheel Drop-thru 1

Dynamic-Link Library - 3.1.1 Changing Mouse Cursor Speed 1

E— Motley AutoHotkey Tips

Editing

word selection lists app - 14.1 AHK Apps Section 1, - 14.1.8 App-TypingAid 2

Education and entertainment scripts - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

EitherMouse app for lefties, the ambidextrous, multiple monitors or multiple mice - 14.1.2 App-EitherMouse 1

Elevate script privileges, Windows Task Scheduler - 16.1.4 BlockInput Problem 1 1

Eliminate Hotkeys - 4.1.3 Menu Eliminates Hotkeys 1

Eliminate Hotkeys with AutoHotkey menus - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, - 4.1.4 Auto Create Shortcuts 3

EnvAdd command (+=) - 1.1 Date Tricks Section 1, 2, - 1.1.1 Date Trick 1 3, - 1.1.2 Date Trick 2 4

ErrorLevel variable when writing AutoHotkey scripts - 16.1 Special Tips and Errors1, - 16.1.2 ClipWait ErrorLevel 2

ErrorLevel, counting characters with AutoHotkey - 9.1 RegEx Section 1, - 16.1 Special Tips and Errors 2, - 16.1.3 Count Char ErrorLevel-RegEx 3

ErrorLevel. If - 7.1.1 Instant Web Searches 1, - 7.1.2 Secret Index AHK Ref1 2, - 7.1.4 Web RegEx AHK Ref2 3, - 8.1.5 Find Colors 4, 5, - 9.1.1 Using RegEx 6, - 9.1.2 Del Dup Words RegEx 7, - 14.1.6 App-GooglePhraseFix 8, - 16.1.2 ClipWait ErrorLevel 9, 10

Escape character - 7.1.7 Web RegEx Tester AHK Ref5 1, - 13.1.3 Hotkey-String Raw2

Escape Character (backtick `) - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2, 3, 4, 5, 6

Escape character, double double-quotes (“”) - 7.1.5 Web RegEx Parse AHK Ref3 1

Escape sequences - 13.1.3 Hotkey-String Raw 1

ExStyle, window status with WinGet, ExStyle - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2

Extended Window Styles (WS_EX_XXXX) - 5.1.2 WinSet Click-thru 1, 2, - 14.1.1 App-Keypad 3

F— Motley AutoHotkey Tips

Failing Hotkeys - 16.1 Special Tips and Errors 1, - 16.1.1 Failing Hotkeys 2

FileAppend command - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 1 2, 3, - 4.1 Menus Section 4, - 4.1.1 Tray Icon Context Menu 5, 6, 7, - 4.1.2 More Tray Menus 8, - 7.1 Web Search Section 9, - 7.1.6 Web INI File AHK Ref4 10, - 10.1 AHK Printing Section 11, - 10.1.1 AHK Printing Made Simple 12, 13, 14, - 10.1.2 MsgBox Print ControlGetText 15, 16, - 16.1.5 BlockInput Problem 2 17

FileCreateDir command - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2

FileCreateShortcut command - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts2, - 4.1.5 Add Menu Icons 3, - 13.1 Misc AHK Tips Section 4, - 13.1.6 Toggle AutoLaunch 5

FileInstall command - 6.1 Education Section 1, 2, - 6.1.1 Talking Text 3, - 6.1.2 Pictures Sound 4

FileRead command - 2.1 Clipboard Tricks Section 1, - 2.1.1 Clipboard Techniques 12, 3, 4, - 7.1 Web Search Section 5, 6, - 7.1.3 Web Search Problems 7, - 7.1.4 Web RegEx AHK Ref2 8, - 7.1.6 Web INI File AHK Ref4 9, 10, - 7.1.8 Tweaking Scripts AHK Ref6 11, 12, - 11.1 GUI Control Data File Section 13, - 11.1.2 Food History and Sorting 14, - 11.1.4 Three GUI Techniques 15, - 14.1.6 App-GooglePhraseFix16, 17, 18

FileSelectFile command - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

Filtering ListView data - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

Finding Icons - 4.1.5 Add Menu Icons 1

Finding Windows Icons - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

Finding Windows icons for AutoHotkey menus - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

For Key [, Value] in Expression command (arrays) - 12.1 GUI Menu Instant Hotkey Section 1, 2, 3, - 12.1.6 Array For Key Loop 4, 5, 6

For Key [, Value] in Expression display order - 12.1.6 Array For Key Loop 1

Forced expression(%) - 14.1.6 App-GooglePhraseFix 1

Forced expressions operator (%) - 3.1.2 Window Transparency Wheel 1, 2, 3, 4, - 5.1 WinSet Command Section 5, - 5.1.5 Window Status WinGet ExStyle 6, 7, 8, 9, - 12.1.3 Two-Deep Variables 10, - 12.1.5 Associative Arrays 11, 12, - 13.1.3 Hotkey-String Raw 13

FormatTime command - 1.1 Date Tricks Section 1, 2, - 1.1.1 Date Trick 1 3, - 1.1.2 Date Trick 2 4

FormatTime() function, V2.0 - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

Formatting Options Chart, GUI controls - 11.1.3 Using Gui Tabs 1

Free AutoHotkey scripts - 9.1 RegEx Section 1, - 9.1.3 Ryans RegEx Tester 2, - 12.1.1 Temporary Hotkeys 3

Free AutoHotkey Scripts and Apps - 1.1.1 Date Trick 1 1, - 9.1 RegEx Section 2, - 9.1.3 Ryans RegEx Tester 3, - 12.1.1 Temporary Hotkeys 4

Free AutoHotkey virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Function for Weekday Date - 1.1 Date Tricks Section 1, - 1.1.2 Date Trick 2 2

Function or command in one-line Hotstring (v1,1,28+) - 6.1 Education Section 1, - 6.1.1 Talking Text 2

Functions

BoundFunc Object - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

ComObjectCreate() - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

DllCall() - 2.1 Clipboard Tricks Section 1, - 2.1.2 Clipboard Techniques 2 2, - 3.1.1 Changing Mouse Cursor Speed 3, - 14.1.2 App-EitherMouse 4

LV_Add() (ListView GUI control) - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

Mathematical - 11.1.6 Variable Type Error 1

OnMessage() - 13.1.5 Optimizing MsgBox 1, - 14.1.2 App-EitherMouse 2

RegExMatch() - 7.1 Web Search Section 1, - 7.1.4 Web RegEx AHK Ref2 2, - 9.1 RegEx Section 3, - 13.1.7 Control EditPaste 4, - 14.1 AHK Apps Section 5, - 14.1.6 App-GooglePhraseFix 6

RegExReplace() - 7.1.4 Web RegEx AHK Ref2 1, - 7.1.5 Web RegEx Parse AHK Ref3 2, 3, - 7.1.6 Web INI File AHK Ref4 4, - 8.1.6 Auto-Insert Color 5, - 9.1 RegEx Section 6, - 9.1.1 Using RegEx 7, - 9.1.2 Del Dup Words RegEx 8, - 13.1.7 Control EditPaste 9, - 16.1 Special Tips and Errors 10, - 16.1.3 Count Char ErrorLevel-RegEx 11

User-defined - 1.1.2 Date Trick 2 1, - 8.1 Windows Automation Section 2, - 8.1.3 Build Tools Automate Paint3 3

Writing - 1.1 Date Tricks Section 1, 2, - 1.1.2 Date Trick 2 3, 4, - 8.1 Windows Automation Section 5, 6, - 8.1.3 Build Tools Automate Paint3 7, 8, - 8.1.4 Control Tools Automate Paint4 9, - 9.1.1 Using RegEx 10, - 9.1.3 Ryans RegEx Tester 11, - 15.1.1 Graph Tools CPU 12

Functions, make your own drawing tools - 8.1 Windows Automation Section 1, - 8.1.3 Build Tools Automate Paint3 2

Functions, user-defined - 1.1 Date Tricks Section 1, - 8.1 Windows Automation Section 2, - 8.1.3 Build Tools Automate Paint3 3

G — Motley AutoHotkey Tips

gLabel, subroutine - 11.1.3 Using Gui Tabs 1, - 11.1.6 Variable Type Error 2

Global variables - 10.1.2 MsgBox Print ControlGetText 1, - 13.1.5 Optimizing MsgBox2

God Mode - 4.1 Menus Section 1, 2, 3, - 4.1.7 God Mode Menu 4, 5, 6, 7

God Mode, add secret Windows tools to QuickLinks menu - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2

GoSub command - 3.1 Mouse Tricks Section 1, - 3.1.3 Transparency Wheel Drop-thru2

GoTo command - 3.1.3 Transparency Wheel Drop-thru 1

Graph, CPU Power - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Graphical User Interface (GUI) pop-up - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2, - 13.1.5 Optimizing MsgBox 3, - 15.1.3 SmartGUI Creator1 4

Graphics files, printing in AutoHotkey - 10.1.1 AHK Printing Made Simple 1

Graphing tools in AutoHotkey - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU2

Greedy RegEx vs. non-greedy - 7.1.5 Web RegEx Parse AHK Ref3 1, 2, - 9.1.1 Using RegEx 3

Greedy RegExs vs. non-greedy RegExs - 9.1.1 Using RegEx 1

GUI

DateTime control - 11.1.1 GUI Controls Calorie Count 1

Hotkey control - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

ListView control - 11.1.1 GUI Controls Calorie Count 1

Tab control - 11.1 GUI Control Data File Section 1, - 11.1.1 GUI Controls Calorie Count 2, - 11.1.2 Food History and Sorting 3, - 11.1.3 Using Gui Tabs 4, 5

GUI (Graphical User Interface) command - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2, - 13.1.5 Optimizing MsgBox 3, - 15.1.3 SmartGUI Creator1 4

GUI Command

Gui, Add - 15.1.3 SmartGUI Creator1 1, 2

GUI control formatting options chart - 11.1.3 Using Gui Tabs 1

GUI control, UpDown - 11.1.6 Variable Type Error 1

GUI Controls, micro-positioning with SmartGUI Creator - 15.1.4 SmartGUI Creator2 1

GUI option, AltSubmit - 11.1.5 GuiContextMenu 1

GUI windows, resizing - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

Gui, Add command - 15.1.3 SmartGUI Creator1 1, 2

Gui, Add, Hotkey command - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

Gui, Color command - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Gui, New command - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

Gui, Tab command - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

GuiClose Label - 5.1.4 WinSet Region 1, - 14.1.1 App-Keypad 2, 3, - 14.1.5 App-StopWatch 4

GuiContextMenu for adding right-click context menus to GUI controls - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

GuiContextMenu, built-in Label subroutine - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

GuiControl command - 11.1.5 GuiContextMenu 1

GUIs, multiple in a single script - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

GUIs, stealing layouts from AutoHotkey windows - 15.1.4 SmartGUI Creator2 1

H — Motley AutoHotkey Tips

Help window, a simple one-line pop-up - 13.1 Misc AHK Tips Section 1, - 13.1.4 Help Pop-up 2

Hidden AutoHotkey.com Index - 7.1.2 Secret Index AHK Ref1 1

Hook, keyboard - 6.1.2 Pictures Sound 1, 2, 3, 4, 5, - 15.1.2 Main Window Debugging6, - 16.1.1 Failing Hotkeys 7, - 16.1.5 BlockInput Problem 2 8

Hotkey combinations, isolate to specific windows - 14.1.9 App-SpeedReader 1

Hotkey command - 3.1.2 Window Transparency Wheel 1, - 4.1.1 Tray Icon Context Menu 2, - 4.1.2 More Tray Menus 3, - 4.1.3 Menu Eliminates Hotkeys 4, - 4.1.5 Add Menu Icons 5, 6, - 4.1.8 Shortcut Icons 7, - 5.1.4 WinSet Region 8, 9, - 5.1.5 Window Status WinGet ExStyle 10, 11, - 7.1.2 Secret Index AHK Ref1 12, 13, 14, - 7.1.3 Web Search Problems 15, - 7.1.8 Tweaking Scripts AHK Ref6 16, 17, - 8.1.1 Shortcuts Automate Paint1 18, - 8.1.6 Auto-Insert Color 19, - 10.1.2 MsgBox Print ControlGetText 20, 21, - 12.1 GUI Menu Instant Hotkey Section 22, - 12.1.1 Temporary Hotkeys 23, - 13.1 Misc AHK Tips Section 24, - 13.1.3 Hotkey-String Raw 25, - 13.1.5 Optimizing MsgBox 26, 27, 28, - 13.1.6 Toggle AutoLaunch 29, - 16.1.2 ClipWait ErrorLevel 30, - 16.1.4 BlockInput Problem 1 31, - 16.1.5 BlockInput Problem 2 32

Hotkey GUI control - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

Hotkey modifier symbols - 13.1.3 Hotkey-String Raw 1

Hotkey Modifiers

ALT (Alternate) Key (!) - 8.1.1 Shortcuts Automate Paint1 1, 2, 3, 4, 5, 6, - 8.1.2 Mouse Control Automate Paint2 7

Ampersand (&) - 7.1.5 Web RegEx Parse AHK Ref3 1, - 8.1.7 WinMenuSelectItem 2

CTRL (Control) Key ( ^) - 3.1.2 Window Transparency Wheel 1, 2, 3, - 16.1.5 BlockInput Problem 2 4

SHIFT key (+) - 1.1.1 Date Trick 1 1, - 1.1.2 Date Trick 2 2, - 15.1.4 SmartGUI Creator2 3

Hotkeys - 2.1.1 Clipboard Techniques 1 1, - 3.1.2 Window Transparency Wheel 2, - 4.1 Menus Section 3, 4, - 4.1.1 Tray Icon Context Menu 5, 6, 7, - 4.1.3 Menu Eliminates Hotkeys 8, 9, - 4.1.7 God Mode Menu 10, - 5.1.5 Window Status WinGet ExStyle 11, - 6.1.2 Pictures Sound 12, - 9.1.1 Using RegEx 13, - 13.1 Misc AHK Tips Section 14, - 13.1.4 Help Pop-up 15, - 16.1 Special Tips and Errors 16, - 16.1.1 Failing Hotkeys 17, - 16.1.2 ClipWait ErrorLevel 18, - About the Author 19

Hotkeys failing - 16.1 Special Tips and Errors 1, - 16.1.1 Failing Hotkeys 2

Hotkeys, drop-through - 3.1.3 Transparency Wheel Drop-thru 1

Hotkeys, eliminate Hotkeys with AutoHotkey menus - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, - 4.1.4 Auto Create Shortcuts 3

Hotkeys, Raw option in Send commands and Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Hotkeys, send Hotkeys with Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.2 Hotstring Secret 2

Hotkeys, temporary for text insertion - 2.1 Clipboard Tricks Section 1, - 12.1 GUI Menu Instant Hotkey Section 2, - 12.1.1 Temporary Hotkeys 3

Hotkeys, two-deep variables for tracking - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2

Hotstring

Replacement - 14.1.7 App-PhraseOMatic 1

Special characters - 13.1.3 Hotkey-String Raw 1

Hotstring Options

?, activate inside string - 13.1.1 Preventing Hotstring Misfires 1

Hotstring techniques, advanced - 6.1 Education Section 1, - 6.1.1 Talking Text 2

Hotstring, X option - 6.1.1 Talking Text 1

Hotstring, Z option - 6.1.1 Talking Text 1

Hotstrings

{Enter} - 3.1.4 Block Mouse 1, - 8.1.1 Shortcuts Automate Paint1 2, 3, 4, 5, - 8.1.2 Mouse Control Automate Paint2 6, 7, 8, - 8.1.3 Build Tools Automate Paint3 9, 10, 11, 12, - 8.1.4 Control Tools Automate Paint4 13, 14, 15, 16, 17, 18, - 8.1.5 Find Colors 19, - 13.1.3 Hotkey-String Raw 20, 21, 22

{Space} - 13.1.3 Hotkey-String Raw 1, 2

Blocking activation - 13.1 Misc AHK Tips Section 1, - 13.1.1 Preventing Hotstring Misfires 2

Disabling select Hotstrings to prevent replacement misfires - 13.1 Misc AHK Tips Section 1, - 13.1.1 Preventing Hotstring Misfires 2

One-line functions (v1,1,28+) - 6.1 Education Section 1, - 6.1.1 Talking Text 2

Raw option in Send commands and Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Secret undocumented feature - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Send Hotkeys with Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.2 Hotstring Secret 2

HTML tags - 7.1 Web Search Section 1, - 7.1.5 Web RegEx Parse AHK Ref3 2, 3

HTML Tags, stripping - 7.1.5 Web RegEx Parse AHK Ref3 1

I — Motley AutoHotkey Tips

Icons for Windows shortcuts - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

Icons, adding to Menus - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2

Icons, Finding - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

Icons, finding - 4.1.5 Add Menu Icons 1

Icons, setting for Windows shortcuts - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

Icons, Windows for AutoHotkey menus - 4.1 Menus Section 1, - 4.1.6 Finding Icons2

If conditionals - 12.1.4 Matching Loops 1, - 16.1 Special Tips and Errors 2, - 16.1.2 ClipWait ErrorLevel 3

If ErrorLevel - 7.1.1 Instant Web Searches 1, - 7.1.2 Secret Index AHK Ref1 2, - 7.1.4 Web RegEx AHK Ref2 3, - 8.1.5 Find Colors 4, 5, - 9.1.1 Using RegEx 6, - 9.1.2 Del Dup Words RegEx 7, - 14.1.6 App-GooglePhraseFix 8, - 16.1.2 ClipWait ErrorLevel 9, 10

IfExist command - 4.1.4 Auto Create Shortcuts 1, - 7.1.8 Tweaking Scripts AHK Ref62

IfInString command - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2, - 7.1.4 Web RegEx AHK Ref2 3

IfMsgBox command - 13.1.5 Optimizing MsgBox 1

IfNotExist command - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2, 3, - 7.1.8 Tweaking Scripts AHK Ref6 4, 5, - 14.1.4 App-TinyShuffleMusic 6

IfWinActive command - 10.1.2 MsgBox Print ControlGetText 1

ImageList (IL) function, ListView GUI - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

ImageList.ahk icon viewer - 14.1.2 App-EitherMouse 1

ImageSearch command - 8.1.5 Find Colors 1

Index secret for AutoHotkey Command Reference - 7.1.2 Secret Index AHK Ref1 1

Index, secret AutoHotkey - 7.1 Web Search Section 1, 2, - 7.1.2 Secret Index AHK Ref1 3, 4, - 7.1.3 Web Search Problems 5, 6, 7, - 7.1.4 Web RegEx AHK Ref2 8, 9, - 7.1.5 Web RegEx Parse AHK Ref3 10, - 7.1.6 Web INI File AHK Ref4 11, - 7.1.7 Web RegEx Tester AHK Ref5 12, - 7.1.8 Tweaking Scripts AHK Ref6 13

INI data files, building - 7.1.7 Web RegEx Tester AHK Ref5 1

INI Files - 7.1 Web Search Section 1, - 7.1.6 Web INI File AHK Ref4 2, 3

INI files to fix Web Address (URL) Case-Sensitivity Problems - 7.1 Web Search Section 1, - 7.1.6 Web INI File AHK Ref4 2

INI lookup table - 6.1.2 Pictures Sound 1, - 7.1.6 Web INI File AHK Ref4 2

IniRead command - 6.1.2 Pictures Sound 1, - 7.1.6 Web INI File AHK Ref4 2

Input command - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, - 1.1.2 Date Trick 23, - 3.1 Mouse Tricks Section 4, - 3.1.4 Block Mouse 5, - 8.1 Windows Automation Section 6, 7, 8, - 8.1.1 Shortcuts Automate Paint1 9, - 8.1.4 Control Tools Automate Paint4 10, - 8.1.5 Find Colors 11, - 8.1.6 Auto-Insert Color 12, - 12.1.4 Matching Loops 13, - 12.1.5 Associative Arrays 14, - 13.1.3 Hotkey-String Raw 15, - 13.1.5 Optimizing MsgBox 16, - 16.1.4 BlockInput Problem 1 17, 18, 19, - 16.1.5 BlockInput Problem 2 20

Inserting Color Data into the Windows Paint palette - 8.1.6 Auto-Insert Color 1, - 9.1 RegEx Section 2

Inserting Data into Multiple Fields Using Regular Expressions - 8.1.6 Auto-Insert Color 1

Inserting next Friday's date, trick - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

InstantHotkey.ahk script - 9.1 RegEx Section 1, - 9.1.3 Ryans RegEx Tester 2, - 12.1 GUI Menu Instant Hotkey Section 3, 4, 5, 6, - 12.1.1 Temporary Hotkeys 7, - 12.1.2 Multi-GUI Scripts 8, 9, 10, 11, - 12.1.3 Two-Deep Variables 12, 13, - 12.1.5 Associative Arrays 14, 15, - 12.1.6 Array For Key Loop 16, - 13.1.3 Hotkey-String Raw 17, 18

Isolate Hotkey combinations to specific windows - 14.1.9 App-SpeedReader 1

K — Motley AutoHotkey Tips

Keyboard hook - 6.1.2 Pictures Sound 1, 2, 3, 4, 5, - 15.1.2 Main Window Debugging6, - 16.1.1 Failing Hotkeys 7, - 16.1.5 BlockInput Problem 2 8

Keyboard, blocking action - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

KeyHistory command (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

Keys

NumLock - 14.1.1 App-Keypad 1

Keys stuck down by the BlockInput command - 16.1.5 BlockInput Problem 2 1

KeyWait alternative use, pausing the script - 16.1.5 BlockInput Problem 2 1

KeyWait command - 16.1.5 BlockInput Problem 2 1

KeyWait command to stop keys stuck down by the BlockInput command - 16.1.5 BlockInput Problem 2 1

L — Motley AutoHotkey Tips

Label name drop-through behavior - 3.1 Mouse Tricks Section 1, - 3.1.3 Transparency Wheel Drop-thru 2

Label subroutine - 15.1.4 SmartGUI Creator2 1

Label, GuiClose - 5.1.4 WinSet Region 1, - 14.1.1 App-Keypad 2, 3, - 14.1.5 App-StopWatch 4

Launch apps at Windows startup - 13.1 Misc AHK Tips Section 1, - 13.1.6 Toggle AutoLaunch 2

Line continuation - 3.1.1 Changing Mouse Cursor Speed 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.7 God Mode Menu 3, - 4.1.8 Shortcut Icons 4, - 5.1.4 WinSet Region 5, - 5.1.5 Window Status WinGet ExStyle 6, - 7.1.2 Secret Index AHK Ref17, - 7.1.8 Tweaking Scripts AHK Ref6 8, - 8.1.6 Auto-Insert Color 9, - 9.1.1 Using RegEx 10, - 10.1 AHK Printing Section 11, - 10.1.1 AHK Printing Made Simple 12, - 12.1.6 Array For Key Loop 13, - 13.1.4 Help Pop-up 14, - 13.1.6 Toggle AutoLaunch 15, - 14.1.6 App-GooglePhraseFix 16, - 16.1.3 Count Char ErrorLevel-RegEx 17

ListHotkeys command (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

ListLines command (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

ListVars command (Main Window) - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2, 3

ListView GUI control - 11.1.1 GUI Controls Calorie Count 1

ListView GUI, ImageList (IL) function, - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

Listview, selecting alternative, Gui, ListView - 11.1.1 GUI Controls Calorie Count 1, - 11.1.3 Using Gui Tabs 2, 3, 4, - 11.1.4 Three GUI Techniques 5, 6, 7, - 11.1.5 GuiContextMenu 8

Locate buttons in Windows programs by color - 8.1 Windows Automation Section1, - 8.1.5 Find Colors 2

Locating Icons - 4.1.5 Add Menu Icons 1

LongDate format - 1.1.2 Date Trick 2 1

Lookup table, INI file - 6.1.2 Pictures Sound 1, - 7.1.6 Web INI File AHK Ref4 2

Loop command - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 8.1 Windows Automation Section 3, - 8.1.2 Mouse Control Automate Paint2 4, - 9.1 RegEx Section 5, - 12.1 GUI Menu Instant Hotkey Section 6, 7, - 12.1.4 Matching Loops 8, - 12.1.5 Associative Arrays 9, - 12.1.6 Array For Key Loop 10

Loop, Parse command - 11.1 GUI Control Data File Section 1, - 11.1.2 Food History and Sorting 2

LV_Add() function (ListView GUI control) - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

M — Motley AutoHotkey Tips

Main Window - 12.1.7 One-click Tray Icons 1, 2, 3, 4, 5, 6, - 15.1 AHK Tools Section7, 8, - 15.1.2 Main Window Debugging 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26

Main Window for debugging AutoHotkey scripts - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2

Main Window KeyHistory Command - 15.1.2 Main Window Debugging 1

Main Window ListHotkeys Command - 15.1.2 Main Window Debugging 1

Main Window ListLines Command - 15.1.2 Main Window Debugging 1

Main Window ListVars Command - 15.1.2 Main Window Debugging 1

Make a window transparent using the WinSet command - 5.1 WinSet Command Section 1, - 5.1.1 WinSet Transparent 2

Make simple instant Web page searches your online thesaurus - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Marco text replacement %var% - 12.1.3 Two-Deep Variables 1

Matching Instant Hotkey combinations with a Loop - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.4 Matching Loops 2

Mathematical functions - 11.1.6 Variable Type Error 1

Menu command - 1.1.2 Date Trick 2 1, - 4.1 Menus Section 2, 3, - 4.1.1 Tray Icon Context Menu 4, - 4.1.2 More Tray Menus 5, 6, - 4.1.3 Menu Eliminates Hotkeys 7, 8, - 4.1.5 Add Menu Icons 9, - 5.1.1 WinSet Transparent 10, - 12.1.7 One-click Tray Icons 11, - 13.1.6 Toggle AutoLaunch 12

Menu, Ribbon - 8.1.1 Shortcuts Automate Paint1 1

Menu, Submenus - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2, 3, 4, 5, - 4.1.5 Add Menu Icons 6, - 12.1.7 One-click Tray Icons 7, - 14.1.7 App-PhraseOMatic 8, 9, 10

Menu, System Tray icon (right-click) - 4.1.1 Tray Icon Context Menu 1, - 15.1.2 Main Window Debugging 2

Menu, toggling action - 4.1.1 Tray Icon Context Menu 1

Menu, toggling Checkmarks - 4.1.1 Tray Icon Context Menu 1

Menu, Tray, Click command - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Menu, Tray, Default command - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Menu, Tray, NoIcon command (remove icon) - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

Menu, Tray, Tip - 8.1.6 Auto-Insert Color 1, 2

Menu. QuickLinks.ahk - 4.1 Menus Section 1, 2, 3, - 4.1.3 Menu Eliminates Hotkeys4, 5, 6, 7, 8, 9, 10, 11, 12, 13, - 4.1.4 Auto Create Shortcuts 14, 15, 16, 17, 18, 19, 20, - 4.1.5 Add Menu Icons 21, 22, 23, 24, 25, 26, - 4.1.6 Finding Icons 27, - 4.1.7 God Mode Menu 28, 29, - 4.1.8 Shortcut Icons 30, 31, 32, 33, 34, - 9.1.3 Ryans RegEx Tester 35, - 10.1 AHK Printing Section 36

Menus for inputting common phrases - 12.1.1 Temporary Hotkeys 1, - 14.1.7 App-PhraseOMatic 2

Menus, ribbon - 8.1.7 WinMenuSelectItem 1

Menus, right-click context, GuiContextMenu for adding menus to GUI controls - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

Menus, spice up with icons - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2

Menus, stuffing more into AutoHotkey pop-up menus - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2

Message Box, adding a fourth button (Help) - 10.1.2 MsgBox Print ControlGetText1, - 13.1.5 Optimizing MsgBox 2

Micro-Positioning GUI Controls with SmartGUI Creator - 15.1.4 SmartGUI Creator21

Mini-tutorial on how RegEx works - 9.1.1 Using RegEx 1

Misic, background - 14.1 AHK Apps Section 1, - 14.1.4 App-TinyShuffleMusic 2

Mouse buttons, XButton - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, 3, 4, - 12.1.1 Temporary Hotkeys 5, - 15.1.2 Main Window Debugging 6

Mouse click-thru transparent windows - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Mouse coordinates, find with Window Spy utility - 5.1.3 WinSet TransColor 1, - 8.1.1 Shortcuts Automate Paint1 2, - 8.1.5 Find Colors 3, 4, 5, 6, - 10.1.2 MsgBox Print ControlGetText 7, - 13.1.7 Control EditPaste 8, - 15.1.2 Main Window Debugging 9

Mouse cursor movement, slowing down - 3.1.1 Changing Mouse Cursor Speed 1

Mouse deactivaton - 8.1.4 Control Tools Automate Paint4 1

Mouse Spotlight script - 5.1.4 WinSet Region 1

Mouse utility software for changing a Hotkey to special mouse button - 14.1.7 App-PhraseOMatic 1

Mouse, blocking action - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Mouse, using extra buttons (XButton1, XButton2) - 14.1.7 App-PhraseOMatic 1

MouseClick command - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint1 2

MouseClickDrag command - 3.1 Mouse Tricks Section 1, - 3.1.4 Block Mouse 2

MouseGetPos command - 3.1 Mouse Tricks Section 1, - 3.1.2 Window Transparency Wheel 2, - 6.1 Education Section 3, - 6.1.1 Talking Text 4

MouseMove command - 8.1 Windows Automation Section 1, 2, - 8.1.1 Shortcuts Automate Paint1 3, - 8.1.2 Mouse Control Automate Paint2 4

MousePrecise.ahk script - 8.1.6 Auto-Insert Color 1, - 14.1.1 App-Keypad 2, - 15.1.2 Main Window Debugging 3

Move Group in SmartGUI Creator - 15.1.4 SmartGUI Creator2 1

MsgBox command - 2.1.1 Clipboard Techniques 1 1, - 2.1.2 Clipboard Techniques 22, - 4.1.1 Tray Icon Context Menu 3, - 7.1 Web Search Section 4, - 7.1.5 Web RegEx Parse AHK Ref3 5, - 7.1.8 Tweaking Scripts AHK Ref6 6, - 8.1.6 Auto-Insert Color 7, - 12.1.6 Array For Key Loop 8, - 13.1.4 Help Pop-up 9, - 13.1.5 Optimizing MsgBox 10, 11, 12

MsgBox, changing buttons names - 13.1 Misc AHK Tips Section 1, - 13.1.5 Optimizing MsgBox 2, - 14.1.2 App-EitherMouse 3

MsgBox, optimizing - 7.1.8 Tweaking Scripts AHK Ref6 1

MsgBox, three-button Message Box - 13.1.5 Optimizing MsgBox 1

Multiple file formats, printing with LibreOffice - 10.1.1 AHK Printing Made Simple 1

Multiple GUIs in a single script - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

N — Motley AutoHotkey Tips

Names, changing buttons, MsgBox - 13.1 Misc AHK Tips Section 1, - 13.1.5 Optimizing MsgBox 2, - 14.1.2 App-EitherMouse 3

Navigating programs with built-in shortcuts - 8.1.1 Shortcuts Automate Paint1 1

Negative look-ahead assertion (RegEx) - 9.1.3 Ryans RegEx Tester 1, 2

Negative RegEx matching - 9.1.1 Using RegEx 1

Never active, yet click-able virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Notepad printing in AutoHotkey - 10.1.1 AHK Printing Made Simple 1

Numeric keypad, virtual - 14.1.1 App-Keypad 1, 2

NumLock key - 14.1.1 App-Keypad 1

O — Motley AutoHotkey Tips

OnClipboardChange Command - 2.1 Clipboard Tricks Section 1, 2, 3, - 2.1.2 Clipboard Techniques 2 4, 5, 6, 7, 8, 9, 10, 11

OnClipboardChange EventInfo variable - 2.1 Clipboard Tricks Section 1, 2, 3, - 2.1.2 Clipboard Techniques 2 4, 5, 6, 7, 8, 9, 10, 11

OnClipboardChange subroutine - 2.1 Clipboard Tricks Section 1, 2, 3, - 2.1.2 Clipboard Techniques 2 4, 5, 6, 7, 8, 9, 10, 11

One-Click Action Buttons, AutoHotkey System Tray Icons - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Online Thesaurus - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

OnMessage() function - 13.1.5 Optimizing MsgBox 1, - 14.1.2 App-EitherMouse 2

Opaqueness, window - 3.1.2 Window Transparency Wheel 1, 2, 3, - 3.1.3 Transparency Wheel Drop-thru 4, - 5.1.1 WinSet Transparent 5, 6, 7, 8, 9, - 5.1.2 WinSet Click-thru 10

Opaqueness, windows - 5.1 WinSet Command Section 1, - 5.1.2 WinSet Click-thru 2

Operators

? : Ternary (single line conditional) - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2, 3, 4

Forced expressions (%) - 3.1.2 Window Transparency Wheel 1, 2, 3, 4, - 5.1 WinSet Command Section 5, - 5.1.5 Window Status WinGet ExStyle 6, 7, 8, 9, - 12.1.3 Two-Deep Variables 10, - 12.1.5 Associative Arrays 11, 12, - 13.1.3 Hotkey-String Raw 13

Optimizing AutoHotkey Message Box - 7.1.8 Tweaking Scripts AHK Ref6 1

Options, adding to GUI controls SmartGUI Creator - 15.1.4 SmartGUI Creator2 1

Options, formatting GUI controls chart - 11.1.3 Using Gui Tabs 1

P — Motley AutoHotkey Tips

Paint, Control Windows programs - 8.1 Windows Automation Section 1, 2, - 8.1.1 Shortcuts Automate Paint1 3, - 8.1.2 Mouse Control Automate Paint2 4, 5

Parse - 4.1.4 Auto Create Shortcuts 1, - 7.1 Web Search Section 2, 3, - 7.1.3 Web Search Problems 4, 5, - 7.1.4 Web RegEx AHK Ref2 6, - 7.1.5 Web RegEx Parse AHK Ref3 7, - 7.1.6 Web INI File AHK Ref4 8, 9, 10, 11, - 7.1.7 Web RegEx Tester AHK Ref5 12, - 7.1.8 Tweaking Scripts AHK Ref6 13, - 8.1.6 Auto-Insert Color 14, 15, 16, - 11.1 GUI Control Data File Section 17, - 11.1.1 GUI Controls Calorie Count18, - 11.1.2 Food History and Sorting 19, 20, 21, 22, 23, - 11.1.4 Three GUI Techniques 24, 25, 26, 27, 28, - 11.1.5 GuiContextMenu 29, - 13.1.5 Optimizing MsgBox 30, - 13.1.6 Toggle AutoLaunch 31, - 14.1.6 App-GooglePhraseFix 32

Parsing data, StringSplit command - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

Pause a script with KeyWait - 16.1.5 BlockInput Problem 2 1

PDF files, printing - 10.1.1 AHK Printing Made Simple 1

PhraseOMatic for replacing the Windows Clipboard - 12.1.1 Temporary Hotkeys 1, - 14.1.7 App-PhraseOMatic 2

PhraseOMatic, Clipboard-like AutoHotkey Apps - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

PixelGetColor command - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

PixelSearch command - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

Print multiple file formats with LibreOffice - 10.1.1 AHK Printing Made Simple 1

Printing graphics files in AutoHotkey - 10.1.1 AHK Printing Made Simple 1

Printing in AutoHotkey - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2, 3, 4, 5, 6, 7, 8, 9, - 5.1.5 Window Status WinGet ExStyle 10, - 10.1 AHK Printing Section 11, 12, 13, 14, 15, - 10.1.1 AHK Printing Made Simple 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, - 10.1.2 MsgBox Print ControlGetText 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45

Printing in AutoHotkey, Notepad Versus Wordpad - 10.1.1 AHK Printing Made Simple 1

Printing PDF files - 10.1.1 AHK Printing Made Simple 1

Printing with AutoHotkey made simple - 10.1 AHK Printing Section 1, - 10.1.1 AHK Printing Made Simple 2, - 10.1.2 MsgBox Print ControlGetText 3

Privileges elevate script, Windows Task Scheduler - 16.1.4 BlockInput Problem 1 1

Problems accessing Web data - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2

Program automation, Windows - 8.1 Windows Automation Section 1, 2, 3, - 8.1.1 Shortcuts Automate Paint1 4, - 8.1.2 Mouse Control Automate Paint2 5, 6, - 8.1.3 Build Tools Automate Paint3 7

Pseudo-array - 11.1.2 Food History and Sorting 1, - 12.1 GUI Menu Instant Hotkey Section 2, 3, - 12.1.2 Multi-GUI Scripts 4, - 12.1.3 Two-Deep Variables 5, 6, - 12.1.4 Matching Loops 7, 8, 9, - 12.1.5 Associative Arrays 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - 12.1.6 Array For Key Loop 20, 21, - 15.1.2 Main Window Debugging 22

Q — Motley AutoHotkey Tips

QuickLinks.ahk menu script - 4.1 Menus Section 1, 2, 3, - 4.1.3 Menu Eliminates Hotkeys 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, - 4.1.4 Auto Create Shortcuts 14, 15, 16, 17, 18, 19, 20, - 4.1.5 Add Menu Icons 21, 22, 23, 24, 25, 26, - 4.1.6 Finding Icons 27, - 4.1.7 God Mode Menu 28, 29, - 4.1.8 Shortcut Icons 30, 31, 32, 33, 34, - 9.1.3 Ryans RegEx Tester 35, - 10.1 AHK Printing Section 36

R — Motley AutoHotkey Tips

Raising user privileges for the BlockInput command - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Random command - 14.1 AHK Apps Section 1, - 14.1.4 App-TinyShuffleMusic 2

Random order, play MP3 files - 14.1 AHK Apps Section 1, - 14.1.4 App-TinyShuffleMusic 2

Range […] of options, (RegEx) - 9.1.1 Using RegEx 1

Raw option in Send commands and Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Reference tool, AutoHotkey commands - 7.1.2 Secret Index AHK Ref1 1

Reference Tool, AutoHotkey V1.1 - 7.1.2 Secret Index AHK Ref1 1

RegEx backreference - 7.1.5 Web RegEx Parse AHK Ref3 1, - 7.1.7 Web RegEx Tester AHK Ref5 2, 3, - 8.1.6 Auto-Insert Color 4, 5, - 9.1.1 Using RegEx 6, 7, 8, 9, 10, 11, 12, - 9.1.2 Del Dup Words RegEx 13, 14, 15, 16, - 9.1.3 Ryans RegEx Tester 17, 18, 19, 20, 21, 22

RegEx Tester - 7.1 Web Search Section 1, 2, - 7.1.5 Web RegEx Parse AHK Ref3 3, - 7.1.6 Web INI File AHK Ref4 4, 5, - 7.1.7 Web RegEx Tester AHK Ref5 6, 7, 8, 9, 10, 11, 12, - 9.1 RegEx Section 13, 14, - 9.1.1 Using RegEx 15, - 9.1.2 Del Dup Words RegEx 16, - 9.1.3 Ryans RegEx Tester 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 12.1 GUI Menu Instant Hotkey Section 28, - 12.1.1 Temporary Hotkeys 29, 30, - 13.1.7 Control EditPaste 31, 32

RegEx, counting characters with AutoHotkey - 9.1 RegEx Section 1, - 16.1 Special Tips and Errors 2, - 16.1.3 Count Char ErrorLevel-RegEx 3

RegEx, non-greedy ? - 7.1.5 Web RegEx Parse AHK Ref3 1, 2, - 9.1.1 Using RegEx3

RegEx, Regular Expressions - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2, 3, - 7.1.4 Web RegEx AHK Ref2 4, - 7.1.5 Web RegEx Parse AHK Ref3 5, 6, - 9.1 RegEx Section 7, 8, 9, 10, - 9.1.1 Using RegEx 11, 12, - 9.1.2 Del Dup Words RegEx 13

RegEx, Universal “Blah, Blah, Blah” - 7.1.5 Web RegEx Parse AHK Ref3 1

RegExMatch() function - 7.1 Web Search Section 1, - 7.1.4 Web RegEx AHK Ref2 2, - 9.1 RegEx Section 3, - 13.1.7 Control EditPaste 4, - 14.1 AHK Apps Section 5, - 14.1.6 App-GooglePhraseFix 6

RegExReplace() - 7.1.4 Web RegEx AHK Ref2 1, - 7.1.5 Web RegEx Parse AHK Ref32, 3, - 7.1.6 Web INI File AHK Ref4 4, - 8.1.6 Auto-Insert Color 5, - 9.1 RegEx Section 6, - 9.1.1 Using RegEx 7, - 9.1.2 Del Dup Words RegEx 8, - 13.1.7 Control EditPaste 9, - 16.1 Special Tips and Errors 10, - 16.1.3 Count Char ErrorLevel-RegEx 11

Registry, Windows AutoHotkey commands - 14.1.3 App-UnHideFiles 1

RegRead and RegWrite commands for setting Windows Registry data - 14.1 AHK Apps Section 1, - 14.1.3 App-UnHideFiles 2

RegRead command (Windows Registry) - 14.1.2 App-EitherMouse 1, - 14.1.3 App-UnHideFiles 2, - 14.1.7 App-PhraseOMatic 3

Regular Expression

Removing Redundant Text - 9.1.2 Del Dup Words RegEx 1

Subpattern

Backreference - 9.1.1 Using RegEx 1

Regular Expression (RegEx) - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2, 3, - 7.1.4 Web RegEx AHK Ref2 4, - 7.1.5 Web RegEx Parse AHK Ref3 5, 6, - 8.1.6 Auto-Insert Color 7, - 9.1 RegEx Section 8, 9, 10, 11, 12, 13, - 9.1.1 Using RegEx 14, 15, - 9.1.2 Del Dup Words RegEx 16, - 9.1.3 Ryans RegEx Tester 17, 18, - 12.1.1 Temporary Hotkeys 19, - 14.1.6 App-GooglePhraseFix 20

Regular Expressions

Continue matching with the plus sign + - 9.1.1 Using RegEx 1

Greedy RegExs vs. non-greedy RegExs - 9.1.1 Using RegEx 1

Negative look-ahead assertion - 9.1.3 Ryans RegEx Tester 1, 2

Negative RegEx matching - 9.1.1 Using RegEx 1

Regular Expressions in Text Replacement - 9.1 RegEx Section 1, - 9.1.1 Using RegEx 2, - 9.1.3 Ryans RegEx Tester 3

Regular Expressions to Fix Grammar Problems - 14.1 AHK Apps Section 1, - 14.1.6 App-GooglePhraseFix 2

RegWrite command (Windows Registry) - 14.1.2 App-EitherMouse 1, - 14.1.3 App-UnHideFiles 2, - 14.1.7 App-PhraseOMatic 3

Reload command - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2

Reset Hotkeys - 3.1.3 Transparency Wheel Drop-thru 1

Resizing GUI windows - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

Return command - 3.1.3 Transparency Wheel Drop-thru 1, - 4.1.1 Tray Icon Context Menu 2

Rewriting AutoHotkey scripts - 7.1.8 Tweaking Scripts AHK Ref6 1

Ribbon menu - 8.1.1 Shortcuts Automate Paint1 1

Ribbon menus - 8.1.7 WinMenuSelectItem 1

Right-click menus, GuiContextMenu for adding context menus to GUI controls - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

Run As Administrator, BlockInput command - 16.1.4 BlockInput Problem 1 1

Run command - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2, - 10.1 AHK Printing Section 3, - 10.1.1 AHK Printing Made Simple 4, 5, - 12.1.1 Temporary Hotkeys 6, - 12.1.2 Multi-GUI Scripts 7, - 16.1.4 BlockInput Problem 1 8

Ryan’s RegEx Tester - 7.1 Web Search Section 1, 2, - 7.1.5 Web RegEx Parse AHK Ref3 3, - 7.1.6 Web INI File AHK Ref4 4, 5, - 7.1.7 Web RegEx Tester AHK Ref5 6, 7, 8, 9, 10, 11, 12, - 9.1 RegEx Section 13, 14, - 9.1.1 Using RegEx 15, - 9.1.2 Del Dup Words RegEx 16, - 9.1.3 Ryans RegEx Tester 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 12.1 GUI Menu Instant Hotkey Section 28, - 12.1.1 Temporary Hotkeys29, 30, - 13.1.7 Control EditPaste 31, 32

S — Motley AutoHotkey Tips

Script writing philosophy - 7.1.8 Tweaking Scripts AHK Ref6 1

Scripts AutoHotkey (free) - 9.1 RegEx Section 1, - 9.1.3 Ryans RegEx Tester 2, - 12.1.1 Temporary Hotkeys 3

Scripts, Auto-start - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, - 4.1.4 Auto Create Shortcuts 3

Search Web pages, automated - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Secret AutoHotkey index - 7.1 Web Search Section 1, 2, - 7.1.2 Secret Index AHK Ref1 3, 4, - 7.1.3 Web Search Problems 5, 6, 7, - 7.1.4 Web RegEx AHK Ref2 8, 9, - 7.1.5 Web RegEx Parse AHK Ref3 10, - 7.1.6 Web INI File AHK Ref4 11, - 7.1.7 Web RegEx Tester AHK Ref5 12, - 7.1.8 Tweaking Scripts AHK Ref6 13

Secret AutoHotkey.com Index - 7.1.2 Secret Index AHK Ref1 1

Secret index for AutoHotkey Command Reference - 7.1.2 Secret Index AHK Ref1 1

Secret undocumented feature of Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Selecting Listview, Gui, ListView - 11.1.1 GUI Controls Calorie Count 1, - 11.1.3 Using Gui Tabs 2, 3, 4, - 11.1.4 Three GUI Techniques 5, 6, 7, - 11.1.5 GuiContextMenu 8

Send command - 7.1.6 Web INI File AHK Ref4 1, - 8.1.6 Auto-Insert Color 2, - 13.1 Misc AHK Tips Section 3, - 13.1.3 Hotkey-String Raw 4, 5, 6, - 13.1.7 Control EditPaste 7, 8, 9

Send Hotkeys with Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.2 Hotstring Secret 2

SendInput command - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, - 8.1 Windows Automation Section 3, 4, - 8.1.1 Shortcuts Automate Paint1 5, - 8.1.5 Find Colors 6, - 8.1.6 Auto-Insert Color 7, - 12.1.4 Matching Loops 8, - 12.1.5 Associative Arrays 9, - 13.1.3 Hotkey-String Raw 10

SendMessage command - 14.1.2 App-EitherMouse 1

SendMode command (problem?) - 16.1 Special Tips and Errors 1, - 16.1.1 Failing Hotkeys 2

SetKeyDelay command - 13.1.7 Control EditPaste 1

SetTimer command - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2, - 13.1.4 Help Pop-up 3, - 13.1.5 Optimizing MsgBox 4, - 14.1 AHK Apps Section 5, 6, - 14.1.2 App-EitherMouse 7, - 14.1.5 App-StopWatch 8, - 14.1.9 App-SpeedReader9

Setting icons for Windows shortcuts - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

SHIFT key (+) - 1.1.1 Date Trick 1 1, - 1.1.2 Date Trick 2 2, - 15.1.4 SmartGUI Creator2 3

Shortcuts, adding to a menu - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2

Shortcuts, create Windows Shortcuts - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.5 Add Menu Icons 3

Shortcuts, Creating (FileCreateShorcut) - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2

Shortcuts, setting icons for - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

Simple and Associative Arrays - 12.1.5 Associative Arrays 1

Simple variable arrays - 12.1.5 Associative Arrays 1, 2, 3

Sleep command - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint1 2

SmartGUI Creator

Adding Options to GUI Controls - 15.1.4 SmartGUI Creator2 1

Micro-Positioning GUI Controls - 15.1.4 SmartGUI Creator2 1

Move Group - 15.1.4 SmartGUI Creator2 1

Writing AutoHotkey GUI code - 15.1 AHK Tools Section 1, 2, - 15.1.3 SmartGUI Creator1 3, - 15.1.4 SmartGUI Creator2 4

SmartGUI Creator AutoHotkey GUI code generator - 15.1 AHK Tools Section 1, 2, - 15.1.3 SmartGUI Creator1 3, - 15.1.4 SmartGUI Creator2 4

Sort command - 11.1 GUI Control Data File Section 1, - 11.1.2 Food History and Sorting 2, 3

SoundPlay command - 6.1 Education Section 1, 2, - 6.1.1 Talking Text 3, - 14.1 AHK Apps Section 4, - 14.1.4 App-TinyShuffleMusic 5

Speech, ComObjCreate(“SAPI.SpVoice”) - 6.1.2 Pictures Sound 1

Speed Reading Script - 14.1 AHK Apps Section 1, - 14.1.9 App-SpeedReader 2

Speeding up text insertion routines - 13.1.7 Control EditPaste 1

SPI_GETMOUSESPEED - 3.1.1 Changing Mouse Cursor Speed 1

SPI_SETMOUSESPEED - 3.1.1 Changing Mouse Cursor Speed 1

Spice up AutoHotkey menus with icons - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2

SplashImage command - 3.1 Mouse Tricks Section 1, - 3.1.2 Window Transparency Wheel 2, - 6.1 Education Section 3, 4, - 6.1.1 Talking Text 5, - 8.1.6 Auto-Insert Color 6

SplashText command - 8.1.6 Auto-Insert Color 1, - 16.1.5 BlockInput Problem 2 2

SplitPath command - 4.1.4 Auto Create Shortcuts 1, - 13.1 Misc AHK Tips Section 2, - 13.1.6 Toggle AutoLaunch 3

Splitting long lines of code - 3.1.1 Changing Mouse Cursor Speed 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.7 God Mode Menu 3, - 4.1.8 Shortcut Icons 4, - 5.1.4 WinSet Region 5, - 5.1.5 Window Status WinGet ExStyle 6, - 7.1.2 Secret Index AHK Ref1 7, - 7.1.8 Tweaking Scripts AHK Ref6 8, - 8.1.6 Auto-Insert Color 9, -9.1.1 Using RegEx 10, - 10.1 AHK Printing Section 11, - 10.1.1 AHK Printing Made Simple 12, - 12.1.6 Array For Key Loop 13, - 13.1.4 Help Pop-up 14, - 13.1.6 Toggle AutoLaunch 15, - 14.1.6 App-GooglePhraseFix 16, - 16.1.3 Count Char ErrorLevel-RegEx 17

Spotlight script using WinSet, Region - 5.1.4 WinSet Region 1

Standard Clipboard routine - 7.1 Web Search Section 1, 2, - 7.1.2 Secret Index AHK Ref1 3, - 7.1.4 Web RegEx AHK Ref2 4, - 7.1.8 Tweaking Scripts AHK Ref6 5, - 9.1.1 Using RegEx 6, - 14.1.6 App-GooglePhraseFix 7, - 16.1.2 ClipWait ErrorLevel8

Standard Clipboard Routine, ErrorLevel variable - 16.1 Special Tips and Errors 1, - 16.1.2 ClipWait ErrorLevel 2

Stealing GUI layouts from AutoHotkey windows - 15.1.4 SmartGUI Creator2 1

Stop accidental deletions with the BlockInput command - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Stop sticky keys caused by the BlockInput command - 16.1.5 BlockInput Problem 2 1

Stopwatch, two-button stopwatch - 14.1 AHK Apps Section 1, - 14.1.5 App-StopWatch 2

StringReplace command - 7.1 Web Search Section 1, - 7.1.5 Web RegEx Parse AHK Ref3 2, - 11.1.6 Variable Type Error 3, - 16.1 Special Tips and Errors 4, - 16.1.3 Count Char ErrorLevel-RegEx 5

StringSplit command (parsing) - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

Stripping HTML Tags - 7.1.5 Web RegEx Parse AHK Ref3 1

Stuffing more into AutoHotkey pop-up menus - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2

Submenus - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2, 3, 4, 5, - 4.1.5 Add Menu Icons 6, - 12.1.7 One-click Tray Icons 7, - 14.1.7 App-PhraseOMatic 8, 9, 10

Subpattern-Backreference (RegEx) - 9.1.1 Using RegEx 1

subroutine, gLabel - 11.1.3 Using Gui Tabs 1, - 11.1.6 Variable Type Error 2

Subroutine, Label - 15.1.4 SmartGUI Creator2 1

Switch mouse buttons or multiple mice - 14.1.2 App-EitherMouse 1

Switch the actions of a running AutoHotkey script with a click of a system tray right-click menu item - 4.1 Menus Section 1, - 4.1.1 Tray Icon Context Menu 2

Symbols - 9.1.1 Using RegEx 1, 2, 3, 4, - 9.1.2 Del Dup Words RegEx 5, - 9.1.3 Ryans RegEx Tester 6, 7, 8, - 13.1.3 Hotkey-String Raw 9, 10, 11, 12

SysTabControl321 GUI control - 11.1.4 Three GUI Techniques 1

System Tray Icon - 4.1 Menus Section 1, - 4.1.1 Tray Icon Context Menu 2, 3, 4, - 12.1 GUI Menu Instant Hotkey Section 5, - 12.1.7 One-click Tray Icons 6

System Tray icon menu (right-click) - 4.1.1 Tray Icon Context Menu 1, - 15.1.2 Main Window Debugging 2

T — Motley AutoHotkey Tips

Tab GUI control - 11.1 GUI Control Data File Section 1, - 11.1.1 GUI Controls Calorie Count 2, - 11.1.2 Food History and Sorting 3, - 11.1.3 Using Gui Tabs 4, 5

Task Scheduler to elevate script privileges - 16.1.4 BlockInput Problem 1 1

Ternary operator (? : single-line conditional) - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2, 3, 4

Tester, RegEx, Ryan’s - 7.1 Web Search Section 1, 2, - 7.1.5 Web RegEx Parse AHK Ref3 3, - 7.1.6 Web INI File AHK Ref4 4, 5, - 7.1.7 Web RegEx Tester AHK Ref5 6, 7, 8, 9, 10, 11, 12, - 9.1 RegEx Section 13, 14, - 9.1.1 Using RegEx 15, - 9.1.2 Del Dup Words RegEx 16, - 9.1.3 Ryans RegEx Tester 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 12.1 GUI Menu Instant Hotkey Section 28, - 12.1.1 Temporary Hotkeys29, 30, - 13.1.7 Control EditPaste 31, 32

Text Replacement with Regular Expressions - 9.1 RegEx Section 1, - 9.1.1 Using RegEx 2, - 9.1.3 Ryans RegEx Tester 3

Thesaurus, online - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Three-button Message Box (MsgBox) - 13.1.5 Optimizing MsgBox 1

Tips

Access Hotkeys with Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.2 Hotstring Secret 2

Activating ListView controls when switching Tab controls - 11.1.3 Using Gui Tabs 1

Add a second cursor to your computer - 14.1.2 App-EitherMouse 1

Add secret Windows tools (God Mode) to QuickLinks menu - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2

Adding a Fourth Button (Help) to the Message Box - 10.1.2 MsgBox Print ControlGetText 1, - 13.1.5 Optimizing MsgBox 2

Adding a fourth button (Help) to the Message Box (MsgBox) - 10.1.2 MsgBox Print ControlGetText 1, - 13.1.5 Optimizing MsgBox 2

Adding controls to another Tab control - 11.1.3 Using Gui Tabs 1

Adding GUI controls to a Tab control - 11.1.3 Using Gui Tabs 1

Adding Options to GUI Controls SmartGUI Creator - 15.1.4 SmartGUI Creator2 1

Adding Uninveral controls to tabbed GUIs - 11.1.3 Using Gui Tabs 1

ALT key to activate internal keyboard shortcuts - 8.1.1 Shortcuts Automate Paint1 1

Always-on-top virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

AutoHotkey variable arrays tutorial - 12.1.5 Associative Arrays 1

Automatically Create Windows Shortcuts - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.5 Add Menu Icons 3

Automatically launch apps at Windows startup - 13.1 Misc AHK Tips Section 1, - 13.1.6 Toggle AutoLaunch 2

Auto-start AutoHotkey scripts - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, - 4.1.4 Auto Create Shortcuts 3

Background Music - 14.1 AHK Apps Section 1, - 14.1.4 App-TinyShuffleMusic 2

Build your own AutoHotkey command reference tool - 7.1.2 Secret Index AHK Ref1 1

Case-sensitivity problems in Web Addresses (URL) - 7.1 Web Search Section 1, - 7.1.6 Web INI File AHK Ref4 2

Change window shapes using the WinSet, Region command - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2

Changing a Hotkey to special mouse button - 14.1.7 App-PhraseOMatic 1

Changing Message Box (MsgBox) button actions - 13.1.5 Optimizing MsgBox 1

Changing Message Box (MsgBox) button names - 13.1.5 Optimizing MsgBox 1

Charting tools in AutoHotkey - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Check for the existence of the INI file - 7.1.8 Tweaking Scripts AHK Ref6 1

Click-able, yet never active virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Clipboard-like AutoHotkey Apps - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.1 Temporary Hotkeys 2

Color, find with Window Spy utility - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

Coloretta Viva color picking script - 8.1.6 Auto-Insert Color 1, 2

Commands for displaying information - 8.1.6 Auto-Insert Color 1

Control, EditPaste for fast text insertion in GUI Edit Controls - 13.1.7 Control EditPaste 1

Control, EditPaste for speed text insertion in EDIT controls - 13.1 Misc AHK Tips Section 1, - 13.1.7 Control EditPaste 2

Counting characters with AutoHotkey (ErrorLevel

RegEx) - 9.1 RegEx Section 1, - 16.1 Special Tips and Errors 2, - 16.1.3 Count Char ErrorLevel-RegEx 3

CPU Power Graph - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Create multiple InstantHotkey GUI pop-ups on-the-fly in a single script - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

Creating a legal variable name - 12.1.3 Two-Deep Variables 1

Creating Windows Shortcuts (FileCreateShorcut) - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2

Data plotting tools - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Deactivating the mouse - 8.1.4 Control Tools Automate Paint4 1

Debugging AutoHotkey scripts, Main Window - 15.1 AHK Tools Section 1, - 15.1.2 Main Window Debugging 2

Disabling select Hotstrings to prevent replacement misfires (? option) - 13.1 Misc AHK Tips Section 1, - 13.1.1 Preventing Hotstring Misfires 2

Display order of For Key [, Value] in Expression (arrays) - 12.1.6 Array For Key Loop 1

Download Web page source code - 14.1 AHK Apps Section 1, - 14.1.6 App-GooglePhraseFix 2

Draw a Straight Line with Pencil tool - 8.1 Windows Automation Section 1, - 8.1.2 Mouse Control Automate Paint2 2, 3

Draw square in Windows Paint - 8.1 Windows Automation Section 1, - 8.1.1 Shortcuts Automate Paint1 2

Drawing polygons in Windows Paint - 8.1.4 Control Tools Automate Paint4 1

Drawing squiggles in Windows Paint - 8.1.4 Control Tools Automate Paint41

EitherMouse app for lefties, the ambidextrous, multiple monitors or multiple mice - 14.1.2 App-EitherMouse 1

Elevate script privileges, Windows Task Scheduler - 16.1.4 BlockInput Problem 1 1

Eliminate Hotkeys with AutoHotkey menus - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, - 4.1.4 Auto Create Shortcuts 3

Entertainment and education scripts - 6.1 Education Section 1, - 6.1.2 Pictures Sound 2

ErrorLevel variable when writing AutoHotkey scripts - 16.1 Special Tips and Errors 1, - 16.1.2 ClipWait ErrorLevel 2

Failing Hotkeys - 16.1 Special Tips and Errors 1, - 16.1.1 Failing Hotkeys 2

Finding Windows Icons - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

Finding Windows icons for AutoHotkey menus - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

Fix Grammar Problems with Google Search and GooglePhraseFix - 14.1 AHK Apps Section 1, - 14.1.6 App-GooglePhraseFix 2

Free AutoHotkey virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Function for Weekday Date - 1.1 Date Tricks Section 1, - 1.1.2 Date Trick 2 2

God Mode, add secret Windows tools to QuickLinks menu - 4.1 Menus Section 1, - 4.1.7 God Mode Menu 2

Graphing tools in AutoHotkey - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

GUI control formatting options chart - 11.1.3 Using Gui Tabs 1

GuiContextMenu for adding right-click context menus to GUI controls - 11.1 GUI Control Data File Section 1, - 11.1.5 GuiContextMenu 2

GUIs, stealing layouts from AutoHotkey windows - 15.1.4 SmartGUI Creator2 1

How to pause a script with KeyWait - 16.1.5 BlockInput Problem 2 1

How to select alternative ListView - 11.1.3 Using Gui Tabs 1

HTML Tags. stripping - 7.1.5 Web RegEx Parse AHK Ref3 1

Icons for Windows shortcuts - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

Icons, Windows for AutoHotkey menus - 4.1 Menus Section 1, - 4.1.6 Finding Icons 2

INI lookup table for case sensitivity - 7.1.6 Web INI File AHK Ref4 1

Inserting Color Data into the Windows Paint palette - 8.1.6 Auto-Insert Color 1, - 9.1 RegEx Section 2

Inserting data into multiple fields - 8.1.6 Auto-Insert Color 1

Isolate Hotkey combinations to specific windows - 14.1.9 App-SpeedReader 1

Keys stuck down by the BlockInput command - 16.1.5 BlockInput Problem 2 1

Launch apps at Windows startup - 13.1 Misc AHK Tips Section 1, - 13.1.6 Toggle AutoLaunch 2

Locate buttons in Windows programs by color - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

Loopin to match Instant Hotkey combinations with text - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.4 Matching Loops 2

Main Window for debugging AutoHotkey scripts - 15.1 AHK Tools Section1, - 15.1.2 Main Window Debugging 2

Make a window transparent using the WinSet command - 5.1 WinSet Command Section 1, - 5.1.1 WinSet Transparent 2

Make simple instant Web page searches your online thesaurus - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Make your own drawing tools with user-defined functions - 8.1 Windows Automation Section 1, - 8.1.3 Build Tools Automate Paint3 2

Matching Instant Hotkey combinations with a Loop - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.4 Matching Loops 2

Menu, toggling Checkmarks - 4.1.1 Tray Icon Context Menu 1

Menus for inputting common phrases - 12.1.1 Temporary Hotkeys 1, - 14.1.7 App-PhraseOMatic 2

Menus, spice up with icons - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2

Micro-Positioning GUI Controls with SmartGUI Creator - 15.1.4 SmartGUI Creator2 1

Missing characters in Send commands and Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Mouse coordinates, find with Window Spy utility - 8.1 Windows Automation Section 1, - 8.1.5 Find Colors 2

MsgBox, adding a fourth button (Help) to the Message Box - 10.1.2 MsgBox Print ControlGetText 1, - 13.1.5 Optimizing MsgBox 2

MsgBox, changing buttons names - 13.1 Misc AHK Tips Section 1, - 13.1.5 Optimizing MsgBox 2, - 14.1.2 App-EitherMouse 3

MsgBox, changing Message Box button actions - 13.1.5 Optimizing MsgBox 1

MsgBox, changing Message Box button names - 13.1.5 Optimizing MsgBox1

Multiple GUIs in a single script - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.2 Multi-GUI Scripts 2

Never active, yet click-able virtual numeric keypad app - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Optimizing AutoHotkey Message Box - 7.1.8 Tweaking Scripts AHK Ref6 1

Packing more into GUI windows - 11.1.1 GUI Controls Calorie Count 1

Print multiple file formats with LibreOffice - 10.1.1 AHK Printing Made Simple 1

Printing graphics files in AutoHotkey - 10.1.1 AHK Printing Made Simple 1

Printing in AutoHotkey, Notepad Versus Wordpad - 10.1.1 AHK Printing Made Simple 1

Printing PDF files - 10.1.1 AHK Printing Made Simple 1

Printing with AutoHotkey made simple - 10.1 AHK Printing Section 1, - 10.1.1 AHK Printing Made Simple 2, - 10.1.2 MsgBox Print ControlGetText3

Raising user privileges for the BlockInput command - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Randomly play MP3 files - 14.1 AHK Apps Section 1, - 14.1.4 App-TinyShuffleMusic 2

Raw option in Send commands and Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

RegEx, Universal “Blah, Blah, Blah” - 7.1.5 Web RegEx Parse AHK Ref3 1

Registry for save filenames and locations - 12.1.1 Temporary Hotkeys 1, - 14.1.7 App-PhraseOMatic 2

RegRead and RegWrite commands for setting Windows Registry data - 14.1 AHK Apps Section 1, - 14.1.3 App-UnHideFiles 2

Regular Expressions in Text Replacement - 9.1 RegEx Section 1, - 9.1.1 Using RegEx 2, - 9.1.3 Ryans RegEx Tester 3

Regular Expressions to Fix Grammar Problems - 14.1 AHK Apps Section 1, - 14.1.6 App-GooglePhraseFix 2

Removing blank rows from ListView GUI control - 11.1.4 Three GUI Techniques 1

Removing duplicate rows from ListView GUI control - 11.1.4 Three GUI Techniques 1

Removing Redundant Text (RegEx) - 9.1.2 Del Dup Words RegEx 1

Replacing the Windows Clipboard with PhraseOMatic menus - 12.1.1 Temporary Hotkeys 1, - 14.1.7 App-PhraseOMatic 2

Resizing GUI windows and controls - 11.1 GUI Control Data File Section 1, - 11.1.4 Three GUI Techniques 2

Rewriting (parsing) and sorting variable list - 11.1.2 Food History and Sorting 1

Ryan’s RegEx Tester - 7.1 Web Search Section 1, 2, - 7.1.5 Web RegEx Parse AHK Ref3 3, - 7.1.6 Web INI File AHK Ref4 4, 5, - 7.1.7 Web RegEx Tester AHK Ref5 6, 7, 8, 9, 10, 11, 12, - 9.1 RegEx Section 13, 14, - 9.1.1 Using RegEx 15, - 9.1.2 Del Dup Words RegEx 16, - 9.1.3 Ryans RegEx Tester 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 12.1 GUI Menu Instant Hotkey Section 28, - 12.1.1 Temporary Hotkeys 29, 30, - 13.1.7 Control EditPaste 31, 32

Ryan’s RegEx Tester for building INI data files - 7.1.7 Web RegEx Tester AHK Ref5 1

Secret index for AutoHotkey Command Reference - 7.1.2 Secret Index AHK Ref1 1

Send mulitple Hotkeys with a Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.2 Hotstring Secret 2

Shortcuts, create Windows Shortcuts - 4.1 Menus Section 1, - 4.1.4 Auto Create Shortcuts 2, - 4.1.5 Add Menu Icons 3

Simple and Associative Arrays - 12.1.5 Associative Arrays 1

Simple one-line pop-up Help window - 13.1 Misc AHK Tips Section 1, - 13.1.4 Help Pop-up 2

SmartGUI Creator AutoHotkey GUI code generator - 15.1 AHK Tools Section 1, 2, - 15.1.3 SmartGUI Creator1 3, - 15.1.4 SmartGUI Creator2 4

Sorting variable lists on a new key - 11.1.2 Food History and Sorting 1

Speed Reading Script - 14.1 AHK Apps Section 1, - 14.1.9 App-SpeedReader2

Speeding up text insertion routines - 13.1.7 Control EditPaste 1

Speeding up the AutoHotkey Reference script - 7.1.8 Tweaking Scripts AHK Ref6 1

Speeding up the Paint drawing function - 8.1.4 Control Tools Automate Paint4 1

Speeding up Web based data access - 7.1.8 Tweaking Scripts AHK Ref6 1

Spice up AutoHotkey menus with icons - 4.1 Menus Section 1, - 4.1.5 Add Menu Icons 2

Stealing GUI layouts from AutoHotkey windows - 15.1.4 SmartGUI Creator2 1

Steps for how the "standard Clipboard routine" - 9.1.1 Using RegEx 1

Stop accidental deletions with the BlockInput command - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Stop sticky keys caused by the BlockInput command - 16.1.5 BlockInput Problem 2 1

Stripping HTML Tags - 7.1.5 Web RegEx Parse AHK Ref3 1

Stuffing more into AutoHotkey pop-up menus - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2

Switch the actions of a running AutoHotkey script with a click of a system tray right-click menu item - 4.1 Menus Section 1, - 4.1.1 Tray Icon Context Menu 2

Temporary Hotkeys for text insertion - 2.1 Clipboard Tricks Section 1, - 12.1 GUI Menu Instant Hotkey Section 2, - 12.1.1 Temporary Hotkeys 3

The "Standard Clipboard Routine" - 9.1.1 Using RegEx 1

Toggle the launch of apps at Windows startup - 13.1 Misc AHK Tips Section 1, - 13.1.6 Toggle AutoLaunch 2

Transparent and mouse click-through window - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

Transparent window using the WinSet command - 5.1 WinSet Command Section 1, - 5.1.1 WinSet Transparent 2

Transparent window, WinSet, ExStyle command, mouse click-thru - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Transparent, mouse click-thru windows - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Trick for inserting next Friday's date - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

Turn AutoHotkey System Tray Icons into One-Click Action Buttons - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Two-button stopwatch (SetTimer) - 14.1 AHK Apps Section 1, - 14.1.5 App-StopWatch 2

Two-deep variables for tracking data - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2

TypingAid App adds word choice to all Windows programs - 14.1 AHK Apps Section 1, - 14.1.8 App-TypingAid 2

Unhide hidden files with windows registry setting to find lost data - 14.1 AHK Apps Section 1, - 14.1.3 App-UnHideFiles 2

Universal “Blah, Blah, Blah” RegEx - 7.1.5 Web RegEx Parse AHK Ref3 1

Using associative arrays to solve the Instant Hotkey data recall problem - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2, - 12.1.5 Associative Arrays 3

Using built-in shortcuts to navigate a program - 8.1.1 Shortcuts Automate Paint1 1

Using the TrayTip command for displaying user information - 8.1.6 Auto-Insert Color 1

Using unique icons for specific Windows shortcuts - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

Variable Types: Text Strings Versus Numbers in AutoHotkey - 11.1 GUI Control Data File Section 1, - 11.1.6 Variable Type Error 2

Window status with WinGet, ExStyle - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2

Window tranparency, WinSet, ExStyle command, mouse click-thru - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

WinSet, ExStyle command for mouse click-thru transparent windows - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Working with the Windows Registry - 14.1.3 App-UnHideFiles 1

Writing AutoHotkey GUI code with SmartGUI Creator - 15.1 AHK Tools Section 1, 2, - 15.1.3 SmartGUI Creator1 3, - 15.1.4 SmartGUI Creator2 4

Tips, Web page searches, your online thesaurus - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Toggle the launch of apps at Windows startup - 13.1 Misc AHK Tips Section 1, - 13.1.6 Toggle AutoLaunch 2

Toggling Menu Checkmarks - 4.1.1 Tray Icon Context Menu 1

Tools, Charting and graphing in AutoHotkey - 15.1 AHK Tools Section 1, - 15.1.1 Graph Tools CPU 2

Tools, Windows - 4.1 Menus Section 1, 2, 3, - 4.1.7 God Mode Menu 4, 5, 6, 7

Tools, Windows God Mode - 4.1 Menus Section 1, 2, 3, - 4.1.7 God Mode Menu 4, 5, 6, 7

Tooltip command - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2

Translucent windows - 5.1 WinSet Command Section 1, - 5.1.2 WinSet Click-thru 2

Transparent and mouse click-through window - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

Transparent vs. mouse click-thru transparent - 5.1.2 WinSet Click-thru 1

Transparent window - 3.1.2 Window Transparency Wheel 1, 2, 3, 4, - 3.1.3 Transparency Wheel Drop-thru 5, - 5.1 WinSet Command Section 6, 7, 8, 9, 10, 11, 12, - 5.1.1 WinSet Transparent 13, 14, 15, 16, 17, 18, 19, 20, - 5.1.2 WinSet Click-thru 21, 22, 23, 24, 25, 26, 27, - 5.1.3 WinSet TransColor 28, - 5.1.4 WinSet Region29, 30, - 5.1.5 Window Status WinGet ExStyle 31, 32, - 14.1 AHK Apps Section 33, - 14.1.1 App-Keypad 34, 35, 36, 37, 38

Transparent window using the WinSet command - 5.1 WinSet Command Section 1, - 5.1.1 WinSet Transparent 2

Transparent window, WinSet, ExStyle command, mouse click-thru - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Transparent, mouse click-thru windows - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Turn AutoHotkey System Tray Icons into One-Click Action Buttons - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.7 One-click Tray Icons 2

Tutorial, AutoHotkey Variable Arrays - 12.1.5 Associative Arrays 1

Two-button stopwatch - 14.1 AHK Apps Section 1, - 14.1.5 App-StopWatch 2

Two-deep variable (derefence) - 3.1.2 Window Transparency Wheel 1, 2, - 12.1 GUI Menu Instant Hotkey Section 3, - 12.1.3 Two-Deep Variables 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, - 12.1.4 Matching Loops 15, 16, - 12.1.5 Associative Arrays 17, - 12.1.6 Array For Key Loop 18, - 13.1.3 Hotkey-String Raw 19

Two-deep variables for tracking data - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2

TypingAid App adds word choice to all Windows programs - 14.1 AHK Apps Section 1, - 14.1.8 App-TypingAid 2

U — Motley AutoHotkey Tips

UAC user privileges and the BlockInput command - 3.1.4 Block Mouse 1, - 16.1.4 BlockInput Problem 1 2

Unhide hidden files with windows registry setting to find lost data - 14.1 AHK Apps Section 1, - 14.1.3 App-UnHideFiles 2

Universal “Blah, Blah, Blah” RegEx - 7.1.5 Web RegEx Parse AHK Ref3 1

UpDown GUI control - 11.1.6 Variable Type Error 1

URLDownloadToFile command - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2

User-defined functions - 1.1 Date Tricks Section 1, - 1.1.2 Date Trick 2 2, - 8.1 Windows Automation Section 3, - 8.1.3 Build Tools Automate Paint3 4

Using associative arrays to solve the Instant Hotkey data recall problem - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2, - 12.1.5 Associative Arrays 3

Using the raw option in Send commands and Hotstrings - 13.1 Misc AHK Tips Section 1, - 13.1.3 Hotkey-String Raw 2

Using unique icons for specific Windows shortcuts - 4.1 Menus Section 1, - 4.1.8 Shortcut Icons 2

V — Motley AutoHotkey Tips

Variable dereferencing - 3.1.2 Window Transparency Wheel 1, 2, - 12.1.3 Two-Deep Variables 3

Variable retrieval, traditional method %var% - 12.1.3 Two-Deep Variables 1

Variable type problems - 11.1.6 Variable Type Error 1

Variable Types: Text Strings Versus Numbers in AutoHotkey - 11.1 GUI Control Data File Section 1, - 11.1.6 Variable Type Error 2

Variable, two-deep variable (derefence) - 3.1.2 Window Transparency Wheel 1, 2, - 12.1 GUI Menu Instant Hotkey Section 3, - 12.1.3 Two-Deep Variables 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, - 12.1.4 Matching Loops 15, 16, - 12.1.5 Associative Arrays17, - 12.1.6 Array For Key Loop 18, - 13.1.3 Hotkey-String Raw 19

Variables

Creating a legal variable name - 12.1.3 Two-Deep Variables 1

Variables Built-in

A_Desktop - 4.1.7 God Mode Menu 1, - 13.1.6 Toggle AutoLaunch 2

A_EventInfo - 2.1.2 Clipboard Techniques 2 1, 2, 3, 4, 5, 6, 7, - 11.1.4 Three GUI Techniques 8, - 11.1.5 GuiContextMenu 9, 10, 11, 12

A_Gui - 11.1.4 Three GUI Techniques 1, 2, 3, 4, 5, 6, - 11.1.5 GuiContextMenu7, 8, 9, 10, 11, 12, 13, - 12.1.3 Two-Deep Variables 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 12.1.4 Matching Loops 25, - 13.1.5 Optimizing MsgBox26

A_GuiWidth - 11.1.4 Three GUI Techniques 1, 2, 3, 4, 5, 6

A_Index (Loop) - 6.1.2 Pictures Sound 1, - 11.1.2 Food History and Sorting 2, 3, 4, 5, - 11.1.4 Three GUI Techniques 6, 7, - 11.1.5 GuiContextMenu 8, 9, - 12.1.4 Matching Loops 10, 11, 12, 13, - 13.1.3 Hotkey-String Raw 14

A_Now - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2, 3, 4, 5, 6, 7, - 1.1.2 Date Trick 2 8, 9, - 3.1.2 Window Transparency Wheel 10, 11, - 4.1.1 Tray Icon Context Menu 12, - 7.1.2 Secret Index AHK Ref1 13, - 7.1.6 Web INI File AHK Ref4 14, - 7.1.8 Tweaking Scripts AHK Ref6 15, 16, - 11.1.4 Three GUI Techniques 17

A_PriorKey - 6.1.2 Pictures Sound 1

A_Space - 7.1.8 Tweaking Scripts AHK Ref6 1, 2

A_Startup built-in variable - 4.1.3 Menu Eliminates Hotkeys 1, - 13.1.6 Toggle AutoLaunch 2, 3, 4, 5, 6

A_ThisHotkey - 12.1 GUI Menu Instant Hotkey Section 1, - 12.1.3 Two-Deep Variables 2, 3, - 12.1.4 Matching Loops 4, 5, - 12.1.5 Associative Arrays 6, 7, 8, - 13.1.3 Hotkey-String Raw 9

A_ThisMenu. Menu variable - 4.1 Menus Section 1, 2, 3, 4, - 4.1.2 More Tray Menus 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, - 4.1.4 Auto Create Shortcuts 19, - 4.1.7 God Mode Menu 20, 21, 22, - 5.1.1 WinSet Transparent 23, 24, - 12.1.2 Multi-GUI Scripts 25, 26

A_ThisMenuItem. Menu variable - 4.1 Menus Section 1, 2, - 4.1.2 More Tray Menus 3, 4, 5, 6, 7, - 4.1.4 Auto Create Shortcuts 8, - 4.1.7 God Mode Menu 9, 10, - 5.1.1 WinSet Transparent 11, 12, - 12.1.2 Multi-GUI Scripts13, 14

A_ThisMenuItemPos. Menu variable - 4.1 Menus Section 1, - 4.1.2 More Tray Menus 2, - 12.1.2 Multi-GUI Scripts 3, 4

A_WDay - 1.1.1 Date Trick 1 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, - 1.1.2 Date Trick 2 11, 12, 13, 14, 15, 16

Variables, associative arrays - 12.1 GUI Menu Instant Hotkey Section 1, 2, 3, - 12.1.2 Multi-GUI Scripts 4, - 12.1.3 Two-Deep Variables 5, 6, 7, 8, - 12.1.4 Matching Loops 9, - 12.1.5 Associative Arrays 10, - 12.1.6 Array For Key Loop 11, 12, 13, 14, - 15.1.2 Main Window Debugging 15

Variables, pseudo-array - 11.1.2 Food History and Sorting 1, - 12.1 GUI Menu Instant Hotkey Section 2, 3, - 12.1.2 Multi-GUI Scripts 4, - 12.1.3 Two-Deep Variables 5, 6, - 12.1.4 Matching Loops 7, 8, 9, - 12.1.5 Associative Arrays 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - 12.1.6 Array For Key Loop 20, 21, - 15.1.2 Main Window Debugging 22

Visual Thesaurus - 7.1.1 Instant Web Searches 1

W — Motley AutoHotkey Tips

Web Address (URL) Letter Case-Sensitivity Problems - 7.1 Web Search Section 1, - 7.1.6 Web INI File AHK Ref4 2

Web data, problems accessing - 7.1 Web Search Section 1, - 7.1.3 Web Search Problems 2

Web page searches, automated - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Web page searches, make your online thesaurus - 7.1 Web Search Section 1, - 7.1.1 Instant Web Searches 2

Web page, download source code - 14.1 AHK Apps Section 1, - 14.1.6 App-GooglePhraseFix 2

Web scraping - 7.1.3 Web Search Problems 1

Web searches, AutoHotkey commands - 7.1.2 Secret Index AHK Ref1 1

Weekdays, calculating dates - 1.1 Date Tricks Section 1, - 1.1.1 Date Trick 1 2

WinClose command - 13.1.5 Optimizing MsgBox 1

Window click-thru - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

Window opaqueness - 3.1.2 Window Transparency Wheel 1, 2, 3, - 3.1.3 Transparency Wheel Drop-thru 4, - 5.1 WinSet Command Section 5, - 5.1.1 WinSet Transparent 6, 7, 8, 9, 10, - 5.1.2 WinSet Click-thru 11, 12

Window shapes, change - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2

Window shapes, the WinSet, Region command - 5.1 WinSet Command Section 1, - 5.1.4 WinSet Region 2

Window Spy utility - 5.1.3 WinSet TransColor 1, - 8.1.1 Shortcuts Automate Paint1 2, - 8.1.5 Find Colors 3, 4, 5, 6, - 10.1.2 MsgBox Print ControlGetText 7, - 13.1.7 Control EditPaste 8, - 15.1.2 Main Window Debugging 9

Window status with WinGet, ExStyle - 5.1 WinSet Command Section 1, - 5.1.5 Window Status WinGet ExStyle 2

Window Styles (WS_XXXX) - 5.1.2 WinSet Click-thru 1

Window Styles, Extended (WS_EX_XXXX) - 5.1.2 WinSet Click-thru 1, 2, - 14.1.1 App-Keypad 3

Window tranparency, WinSet, ExStyle command, mouse click-thru - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Window, mouse click-thru transparent - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

Window, set always-on-top - 5.1 WinSet Command Section 1, 2, - 5.1.1 WinSet Transparent 3, - 5.1.2 WinSet Click-thru 4, 5, - 5.1.5 Window Status WinGet ExStyle 6, 7, 8, 9, - 8.1.6 Auto-Insert Color 10, 11

Window, Transparent - 3.1.2 Window Transparency Wheel 1, 2, 3, 4, - 3.1.3 Transparency Wheel Drop-thru 5, - 5.1 WinSet Command Section 6, 7, 8, 9, 10, 11, 12, - 5.1.1 WinSet Transparent 13, 14, 15, 16, 17, 18, 19, 20, - 5.1.2 WinSet Click-thru 21, 22, 23, 24, 25, 26, 27, - 5.1.3 WinSet TransColor 28, - 5.1.4 WinSet Region29, 30, - 5.1.5 Window Status WinGet ExStyle 31, 32, - 14.1 AHK Apps Section 33, - 14.1.1 App-Keypad 34, 35, 36, 37, 38

Window, transparent and mouse click-through - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

Windows automation, Paint - 8.1 Windows Automation Section 1, 2, - 8.1.1 Shortcuts Automate Paint1 3, - 8.1.2 Mouse Control Automate Paint2 4, 5

Windows Clipboard - 2.1 Clipboard Tricks Section 1, 2, 3, 4, 5, 6, - 2.1.1 Clipboard Techniques 1 7, 8, 9, 10, 11, 12, 13, 14, 15, - 2.1.2 Clipboard Techniques 2 16, 17, 18, 19, - 4.1.4 Auto Create Shortcuts 20, - 4.1.6 Finding Icons 21, - 7.1.1 Instant Web Searches 22, 23, - 7.1.4 Web RegEx AHK Ref2 24, - 7.1.8 Tweaking Scripts AHK Ref6 25, - 8.1.6 Auto-Insert Color 26, 27, - 9.1 RegEx Section 28, - 9.1.1 Using RegEx 29, 30, 31, - 9.1.3 Ryans RegEx Tester 32, - 12.1 GUI Menu Instant Hotkey Section 33, - 12.1.1 Temporary Hotkeys 34, 35, 36, 37, 38, 39, 40, - 13.1.2 Hotstring Secret 41, 42, - 13.1.6 Toggle AutoLaunch 43, - 13.1.7 Control EditPaste44, - 14.1.6 App-GooglePhraseFix 45, 46, - 16.1.2 ClipWait ErrorLevel 47, 48, - 16.1.5 BlockInput Problem 2 49

Windows God Mode - 4.1 Menus Section 1, 2, 3, - 4.1.7 God Mode Menu 4, 5, 6, 7

Windows Message WS_EX_NOACTIVATE 0x08000000L - 14.1 AHK Apps Section 1, - 14.1.1 App-Keypad 2

Windows Paint Automation - 8.1 Windows Automation Section 1, 2, 3, 4, - 8.1.1 Shortcuts Automate Paint1 5, - 8.1.2 Mouse Control Automate Paint2 6, - 8.1.3 Build Tools Automate Paint3 7, - 8.1.4 Control Tools Automate Paint4 8

Windows Registry settings - 14.1.3 App-UnHideFiles 1

Windows Spy - 8.1.5 Find Colors 1, 2, - 8.1.6 Auto-Insert Color 3, - 10.1.2 MsgBox Print ControlGetText 4, - 11.1.4 Three GUI Techniques 5

Windows Task Scheduler to elevate script privileges - 16.1.4 BlockInput Problem 11

Windows Tools - 4.1 Menus Section 1, 2, 3, - 4.1.7 God Mode Menu 4, 5, 6, 7

WinGet command - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4, - 12.1.3 Two-Deep Variables 5

WinMenuSelectItem command - 8.1 Windows Automation Section 1, - 8.1.7 WinMenuSelectItem 2

WinSet command - 5.1 WinSet Command Section 1, - 5.1.1 WinSet Transparent 2, - 5.1.2 WinSet Click-thru 3, 4

WinSet, ExStyle command - 5.1 WinSet Command Section 1, 2, 3, - 5.1.2 WinSet Click-thru 4, 5, 6, 7, 8, 9, 10, 11, 12, - 5.1.5 Window Status WinGet ExStyle 13

WinSet, ExStyle Command - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

WinSet, ExStyle command for mouse click-thru transparent windows - 5.1 WinSet Command Section 1, 2, - 5.1.2 WinSet Click-thru 3, - 5.1.5 Window Status WinGet ExStyle 4

WinSet, Region Command - 5.1 WinSet Command Section 1, 2, - 5.1.4 WinSet Region 3, 4

WinSet, Style command - 5.1 WinSet Command Section 1, - 5.1.2 WinSet Click-thru2, 3, 4, 5, 6, 7, 8

WinSet, TransColor Command - 5.1 WinSet Command Section 1, - 5.1.3 WinSet TransColor 2, - 14.1.1 App-Keypad 3

WinTitle ahk_id - 3.1 Mouse Tricks Section 1, - 3.1.2 Window Transparency Wheel 2, 3, 4, 5, 6, 7, - 3.1.3 Transparency Wheel Drop-thru 8, - 5.1.2 WinSet Click-thru 9, 10, - 5.1.5 Window Status WinGet ExStyle 11, - 14.1.2 App-EitherMouse 12

Word selection lists app - 14.1 AHK Apps Section 1, - 14.1.8 App-TypingAid 2

Wordpad Printing in AutoHotkey, - 10.1.1 AHK Printing Made Simple 1

Working with the Windows Registry - 14.1.3 App-UnHideFiles 1

Writing AutoHotkey Functions - 1.1 Date Tricks Section 1, 2, - 1.1.2 Date Trick 2 3, 4, - 8.1 Windows Automation Section 5, 6, - 8.1.3 Build Tools Automate Paint3 7, 8, - 8.1.4 Control Tools Automate Paint4 9, - 9.1.1 Using RegEx 10, - 9.1.3 Ryans RegEx Tester 11, - 15.1.1 Graph Tools CPU 12

Writing AutoHotkey GUI code with SmartGUI Creator - 15.1 AHK Tools Section 1, 2, - 15.1.3 SmartGUI Creator1 3, - 15.1.4 SmartGUI Creator2 4

X — Motley AutoHotkey Tips

X option Hotstring - 6.1.1 Talking Text 1

XButton, extra mouse buttons - 4.1 Menus Section 1, - 4.1.3 Menu Eliminates Hotkeys 2, 3, 4, - 12.1.1 Temporary Hotkeys 5, - 15.1.2 Main Window Debugging 6

Z — Motley AutoHotkey Tips

Z option Hotstring - 6.1.1 Talking Text 1

Notes:

I broke many of the lines of code in the book into two or more parts. As much as possible, I used line continuation techniques to break the lines. This allows you to copy the code and directly run it without alteration. However, at times, I could not break the lines in a way which would not interfere with its operation. In particular, the chapter on "God Mode" requires you to unwrap certain lines to before you run them.

This book contains numerous Web links to external resources (especially the AutoHotkey online documentation). These require an active Internet connection.

You'll find a limited number of references to the coming AutoHotkey Version 2.0. As the book grows, many more will appear. That does not a comprise a recommendation about either AutoHotkey V1.1 or V2.0, but merely an observation about the changing nature of AutoHotkey. For more information and my opinion about AutoHotkey V2.0 see the blog "AutoHotkey Version 2.0—Should I Wait for It?"

The free book AutoHotkey Tricks You Ought to Do with Windows includes the "Table of Contents" and "Indexes" for all of my AutoHotkey books. You can download it free at the "Free AutoHotkey Book!" site. Plus, you'll find the book included in all major library bundles available at ComputorEdge E-Books.

*                    *                    *

About the Author

Jack Dunning

Jack Dunning was the publisher of ComputorEdge Magazine. He was with the magazine since the first issue on May 16, 1983. Back then, it was called The Byte Buyer. His Web site is www.computoredge.com. He can be reached at computoredge@gmail.com. In March of 2015, ComputorEdge published its last online issue.

Jack has written hundreds of articles and columns about computers and the Internet. He now specializes in Blogs and e-books about AutoHotkey. His current list of e-book titles can be found at ComputorEdge E-Books. He currently writes the blog "Jack's AutoHotkey Blog" for beginning and intermediate AutoHotkey users.

Author of 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, Digging Deeper into AutoHotkey, AutoHotkey Applications and A Beginner's Guide to Using Regular Expressions in AutoHotkey. Jack helps people make their Windows computer run the way they want it to run. These books are also available in EPUB and PDF format at ComputorEdge E-Books.

Jack's two latest books include Beginning AutoHotkey Hotstrings and AutoHotkey Hotkeys: Tips, Tricks, Techniques,and Best Practices.