I made a AutoHotKey Script but I want to convert it into a windows batch file. This is the AutoHotKey script I made below. The "Run ControlMK" and "Run Oblivion Controller" are shortcut files (.lnk). Mainly all it does is open ControlMK, wait a second, press the down arrow key, wait half a second, open Oblivion Controller, and finally open the Oblivion_Steam.url. When I try to make a Batch file that opens the AutoHotKey script it ignores the Sleep commands since the script is located in my Programs (x86) folder and not my documents. Is there a way to make this run in a batch file?
Run ControlMK
Sleep 1000
Send {Down}
Sleep 500
Run Oblivion Controller
Run Oblivion_Steam.url
AutoHotKey to a Batch FIle
Moderator: DosItHelp
Re: AutoHotKey to a Batch FIle
you want to call these commands from a batch file or convert them to native batch ?, the latter is not possible, they can be converted to vbscript but autohotkey is more suitable. This command:cannot be done in native batch.
Code: Select all
Send {Down}
I do not understand, as I assume it would be unlogical for Sleep, to be a non-native command to autohotkey. I'd write this is autoIT as it's way more versatile than autohotkey. Also you should not send key's into the wild, you should lock on to the receiving window first which can be done with autoIT.MrJunky wrote:When I try to make a Batch file that opens the AutoHotKey script it ignores the Sleep commands since the script is located in my Programs (x86) folder and not my documents.
Re: AutoHotKey to a Batch FIle
I figured it out through AutoHotKey! Now it runs without skipping the sleep commands.