机器翻译版本在此:
https://www.helplib.com/Windows/article_10686
原文如下:
The Beginner’s Guide to Using an AutoHotkey Script
EREZ ZUKERMAN
MARCH 21, 2011, 4:00AM EDT
AutoHotkey scripts are a great way to customize your computer, but may seem daunting at first. Don’t worry – getting started is much easier than it looks! Read on to see.
[Image:mlinksva]
Getting AutoHotkey
The first thing you want to do is download and install AutoHotkey. Go to theAutoHotkey download page. You will be presented with a number of download links:
Click the first one, the installer for AutoHotkey_L. Save it to your hard drive – that’s what we’re going to use.
A Bit of History: Why Are There Two Versions?
You may be wondering why the download page offers both AutoHotkey_L and AutoHotkey Basic. What happened is that AutoHotkey’s original developer decided to stop working on the project; but AutoHotkey wouldn’t die so fast. Since the project is open-source and has an vibrant developer community, a number of efforts to continue development were started. Out of these, AutoHotkey_L was chosen as “AutoHotkey’s future”, and is now offered on the official download page.
Installing AutoHotkey
Okay, now that you’ve downloaded the executable, it’s time to set it up. The installer is fairly straightforward except for this next step which offers multiple choices:
We recommend to keep this at the default, Unicode 32-bit. If you’re running a 64-bit version of Windows you could opt for the 64-bit Unicode version, but it doesn’t offer significant performance gains for most scripts. Regarding ANSI, you should only choose this option if there’s a specific script you’d like to run which you know for sure doesn’t play well with Unicode. This very rarely happens. Bottom line: unless you have a good reason, stick to the default and click Next.
Getting The Script: Saving a Snippet
Now that you’ve got AutoHotkey set up, it’s time to get your first script. Some AutoHotkey scripts are so short, they’re posted online as short snippets of text. You can see one such script in our recent post aboutHow to Fake Back and Forward Buttons With a Three-button Mouse. Select the script text and copy it:
Now run Notepad and paste the script in. Make sure you got the whole thing, from the very beginning to the end.
Next, save the file somewhere on your computer. The filename doesn’t matter, but the extension must be AHK. If you installed the Unicode version of AutoHotkey_L, it would be a good idea to save the script with Unicode encoding. Most scripts would probably work if you save them using the default encoding (ANSI), but Unicode is a safe option.
Pro Tip: Understanding Character Encodings
If you find all this talk about Unicode and ANSI a bit confusing, you might want to take a quick look at our recent post explainingWhat Are Character Encodings and How They Differ.
Getting The Script: Saving a File
Some scripts go on for more than just a few lines; these are often offered as files rather than pasted in-page. We recently posted one of these larger scripts underHow to Get Spelling Autocorrect Across All Applications on Your System, so that’s what we’ll use for the example. Right-click the link to the AHK file and select to save it locally:
Again, make sure you save it as an AHK file.
Running The Script
You should now have an AHK file somewhere on your system, and AutoHotkey all set up. Simply double-click the AHK file to run it.
When the script is running, you should see a small icon in your system tray. Hovering over this icon with your mouse will pop up a tooltip showing the name of the script. AutoHotkey and AutoHotkey_L use slightly different icons.
If Your Script Doesn’t Work
Most scripts work right off the bat. However, if your script won’t run and pops up an error message, go back to the AutoHotkey download page and get “AutoHotkey Basic” (the second option). Uninstall AutoHotkey_L, Install AutoHotkey Basic and try running the script again.
You can also go back to “Saving a Snippet” and try saving the script with a different character encoding.
Exiting the Script
When you’re done working with a script, right-click its system tray icon and select Exit.
READ NEXT
- ›How to Change Your Google Stadia Username and Avatar
- ›How to Scan a Document in Windows 10
- ›How to Use the ps Command to Monitor Linux Processes
- ›10 Easy Steps to Better iPhone and iPad Security
- ›Fonts and Browser Extensions That Help Those with Dyslexia Read the Web
1、IT大王遵守相关法律法规,由于本站资源全部来源于网络程序/投稿,故资源量太大无法一一准确核实资源侵权的真实性;
2、出于传递信息之目的,故IT大王可能会误刊发损害或影响您的合法权益,请您积极与我们联系处理(所有内容不代表本站观点与立场);
3、因时间、精力有限,我们无法一一核实每一条消息的真实性,但我们会在发布之前尽最大努力来核实这些信息;
4、无论出于何种目的要求本站删除内容,您均需要提供根据国家版权局发布的示范格式
《要求删除或断开链接侵权网络内容的通知》:https://itdw.cn/ziliao/sfgs.pdf,
国家知识产权局《要求删除或断开链接侵权网络内容的通知》填写说明: http://www.ncac.gov.cn/chinacopyright/contents/12227/342400.shtml
未按照国家知识产权局格式通知一律不予处理;请按照此通知格式填写发至本站的邮箱 wl6@163.com