Hi all, i've looked around bit i can't seem to get any code i've found elsewhere working I'm trying to execute an ahk script via python. I've downloaded the <!-- m -->https://toh.../AutoHotkey.zip<!-- m --> but i'm not sure whether or not to use the files from the "Win32w" or "Win32a" folders. Similarly, can i just put all those files in the same folder as my scripts? I'm using python 2.7 so i guess i'm asking, how do i run a .ahk file in the same folder as my python file, via python. pythoncode.py: import ctypes,time import os, sys ahk = ctypes.cdll.AutoHotkey ahk.ahktextdll("") #start script in persistent mode (wait for action) ahk.ahkdll("ahkTestScript.ahk","","") ahkTestScript.ahk: Run Notepad edit: when i run via IDLE, i get the following error: "WindowsError: exception: access violation reading 0x00000004" at the line: ahk.ahktextdll("") Any help would be appreciated. |
|