Hello,
Often it is very helpful to use the clipboard as a means for interacting with a program. Thankfully AutoHotkey has two built-in variables working with it:
A_Clipboard which reflects the content of the clipboard if it can be expresses as text
ClibpoardALL which contains a lot of different types of data (Images, files, HTML, Audio files, Video file, Rich Text Format/ RTF, etc.)
In this example we’re just going to play a little with Setting and Using A_Clipboard.
The following will send the selected text to the clipboard and then display it in a messagebox.
Send “^c” ;Copying selected text
msgbox A_Clipboard ; Display clipboard in a message box
We cover how to use the FileRead command in our Intermediate AHK v2 Course. Remember that you can get a 15% discount by clicking here.
One thing I like to make sure I do is backup my clipboard, use it with my program, and then restore the clipboard. I walk through this process in this video.
Having programmatic access to the clipboard is crazy useful! There are a lot of other things to learn about accessing and using the clipboard but this gives you the basics to get you started.
Additional Resources
Joe, Isaias, Irfan & Team
This campaign was designed to allow you to jump around. At any time you can jump to any one of the emails by clicking below
P.S. Using the clipboard to get stuff done is great, but we have talked about 18 different ways to automate programs in the AHK Hero Group❗

