The ATA Chronicle - May/June 2021 - 34

RESOURCE REVIEW

By Nora Díaz

Automating Computer Tasks
Is Easier than You Think
Whenever I face a repetitive task, I wonder if there's a way to automate
it to make it go faster. This weekend, for instance, I had to spot over 600
subtitles (i.e., set the times when a subtitle will appear and disappear

AutoHotkey will automatically
appear on my screen. The
syntax for a hotstring is a pair
of colons, the abbreviation
you want to use to trigger
the expansion, and another
pair of colons. After the
second pair of colons, you
enter the expanded text you
want to see when you type

from the screen). This involved the following steps:

the abbreviation. Here's
another example:

wishing I had a macro to

documentation is also

from a waveform in

save time. Since discovering

available.) Once downloaded,

Subtitle Edit.

AutoHotkey, however, I've

install the program. Keep

gone from wishing there was

in mind that installing

a way to speed things up to

AutoHotkey doesn't launch

actually making it happen.

the program automatically

1.	 Select a portion of audio

2.	 Switch over to the file
containing the script
in Notepad++.
3.	 Select the subtitle text.
4.	 Copy the selection to
the clipboard.
5.	 Switch back to
Subtitle Edit.
6.	 Click the right
mouse button.
7.	 Select the second option
from the context menu to
create a new subtitle and
then paste the contents of
the clipboard in it.
These steps needed to be
repeated for each subtitle-

What Is AutoHotkey?
AutoHotkey is a free opensource scripting language
for Windows that allows
users to create macros
to automate all kinds of
repetitive computer tasks in
any Windows application.
AutoHotkey scripts can be
used to launch programs,
open documents, and
emulate keystrokes, Unicode
characters, and mouse clicks
and movements.
The best part is you don't

so, 600 times. Clearly, this

need to be a programming

was a perfect opportunity

whiz to take advantage

to automate a repetitive

of AutoHotkey and start

task. I could have sped up

using it right away. While

the process had I combined

it's powerful enough to

at least some of those steps

allow advanced users to

into a customized macro

create complex automation

(i.e., a saved sequence of

processes, it also allows non-

commands that instructs the

programmers like myself to

computer to perform a given

quickly learn the basics and

task). With a single click or

start creating simple scripts

keyboard shortcut, I could

to suit our needs.

or do anything else, so
don't worry if it looks like
nothing happened.
With AutoHotkey
installed, you're now ready
to start creating your own
sequences of actions to
be launched with one of
two AutoHotkey features:
hotstrings and hotkeys.

Hotstrings
A hotstring is a string (or
sequence) of text typically
composed of more than one
character (usually forming an
abbreviation) that can be used
to trigger any scripted action.
Hotstrings are commonly
used for text expansion.
For example, I can assign
the character string " ak " to
automatically produce the
word AutoHotkey:

::ak::AutoHotkey

:
 :addr::1600
Pennsylvania
Avenue NW,
Washington, DC
20500, United
States
In this example, typing the
hotstring " addr " followed by
an ending character (a space,
a punctuation mark, or the
Enter key) will cause the
address of the White House
to be typed out.

Creating a
Hotstring Script
Now, where do you put these
hotstrings so you can use
them? You put them in an
AutoHotkey script. Follow
the steps below to create
your very first script. (Tip:
If you're like me, you'll
soon have a large number
of scripts, so it makes sense
to create a folder just for
AutoHotkey scripts.)
1.	 In your selected folder,
right-click and select
New-AutoHotkey
Script. Name your script

What you're looking at is

anything you want. (Note

a text expansion triggered

that the extension of

get started? First, go to

by a hotstring. It means that

the new file is " .ahk " .)

www.autohotkey.com and

when I press the keys " ak "

Now you need to add the

download the program. (The

(the hotstring), followed by

hotstrings to the script.

of the many times during

AutoHotkey installation

an ending character (e.g., a

This is done in a plain

my work as a translator

includes its own extensive

space, punctuation mark,

text editor. I suggest

when I've found myself

help file, and web-based

or the Enter key), the word

using Notepad++, which

have activated the macro and
saved repetitive clicks and
key presses.
This is only one example

34

What do you need to

The ATA Chronicle | May/June 2021

www.atanet.org


http://www.autohotkey.com http://www.atanet.org

The ATA Chronicle - May/June 2021

Table of Contents for the Digital Edition of The ATA Chronicle - May/June 2021

Contents
The ATA Chronicle - May/June 2021 - 1
The ATA Chronicle - May/June 2021 - Contents
The ATA Chronicle - May/June 2021 - 3
The ATA Chronicle - May/June 2021 - 4
The ATA Chronicle - May/June 2021 - 5
The ATA Chronicle - May/June 2021 - 6
The ATA Chronicle - May/June 2021 - 7
The ATA Chronicle - May/June 2021 - 8
The ATA Chronicle - May/June 2021 - 9
The ATA Chronicle - May/June 2021 - 10
The ATA Chronicle - May/June 2021 - 11
The ATA Chronicle - May/June 2021 - 12
The ATA Chronicle - May/June 2021 - 13
The ATA Chronicle - May/June 2021 - 14
The ATA Chronicle - May/June 2021 - 15
The ATA Chronicle - May/June 2021 - 16
The ATA Chronicle - May/June 2021 - 17
The ATA Chronicle - May/June 2021 - 18
The ATA Chronicle - May/June 2021 - 19
The ATA Chronicle - May/June 2021 - 20
The ATA Chronicle - May/June 2021 - 21
The ATA Chronicle - May/June 2021 - 22
The ATA Chronicle - May/June 2021 - 23
The ATA Chronicle - May/June 2021 - 24
The ATA Chronicle - May/June 2021 - 25
The ATA Chronicle - May/June 2021 - 26
The ATA Chronicle - May/June 2021 - 27
The ATA Chronicle - May/June 2021 - 28
The ATA Chronicle - May/June 2021 - 29
The ATA Chronicle - May/June 2021 - 30
The ATA Chronicle - May/June 2021 - 31
The ATA Chronicle - May/June 2021 - 32
The ATA Chronicle - May/June 2021 - 33
The ATA Chronicle - May/June 2021 - 34
The ATA Chronicle - May/June 2021 - 35
The ATA Chronicle - May/June 2021 - 36
The ATA Chronicle - May/June 2021 - 37
The ATA Chronicle - May/June 2021 - 38
The ATA Chronicle - May/June 2021 - 39
The ATA Chronicle - May/June 2021 - 40
https://www.nxtbook.com/nxtbooks/chronicle/20240708
https://www.nxtbook.com/nxtbooks/chronicle/20240506
https://www.nxtbook.com/nxtbooks/chronicle/20240304
https://www.nxtbook.com/nxtbooks/chronicle/20240102
https://www.nxtbook.com/nxtbooks/chronicle/20231112
https://www.nxtbook.com/nxtbooks/chronicle/20230910
https://www.nxtbook.com/nxtbooks/chronicle/20230506
https://www.nxtbook.com/nxtbooks/chronicle/20230304
https://www.nxtbook.com/nxtbooks/chronicle/20230102
https://www.nxtbook.com/nxtbooks/chronicle/20221112
https://www.nxtbook.com/nxtbooks/chronicle/20220910
https://www.nxtbook.com/nxtbooks/chronicle/20220708
https://www.nxtbook.com/nxtbooks/chronicle/20220506
https://www.nxtbook.com/nxtbooks/chronicle/20220304
https://www.nxtbook.com/nxtbooks/chronicle/20220102
https://www.nxtbook.com/nxtbooks/chronicle/20211112
https://www.nxtbook.com/nxtbooks/chronicle/20210910
https://www.nxtbook.com/nxtbooks/chronicle/20210708
https://www.nxtbook.com/nxtbooks/chronicle/20210506
https://www.nxtbook.com/nxtbooks/chronicle/20210304
https://www.nxtbook.com/nxtbooks/chronicle/20210102
https://www.nxtbookmedia.com