I just updated to Ahk v2 + AHK_H and I'm facing a compiler issue. I tried to fresh install everything that way :
-> Downloading and installing (as Unicode 32bits, with compiler) AutoHotkey_1.1.27.05.exe
-> Downloading AutoHotkey_2.0-a083-97803ae.zip ( https://autohotkey.com/download/2.0/ ) -> Extracting the whole content in C:\Program Files\AutoHotKey\
-> Deleting C:\Program Files\AutoHotKey\AutoHotkey.exe
-> Downloading ahkdll-v2-release-master.zip ( https://github.com/HotKeyIt/ahkdll-v2-release ) -> Extracting the "Compiler" folder's content in C:\Program Files\AutoHotKey\Compiler -> Extracting the Win32w folder's content in C:\Program Files\AutoHotKey\
-> Creating a .bat file ->
Ahk2Exe.exe /in "C:\Program Files\AutoHotkey\Compiler\Ahk2Exe.ahk" /out "C:\Program Files\AutoHotkey\Compiler\Ahk2ExeH.exe" /bin "C:\Program Files\AutoHotkey\Compiler\Unicode 32-bit.bin"
(To compile the AHK_H's Ahk2Exe.exe)
My issue when running my new Ahk2ExeH.exe is :
Line Text: #DllImport
Error: This line does not contain a recognized action.
I tried almost every "EXETORUN" and "BINWITH" in this bat configuration :
[b]"EXETORUN"[/b] /in "C:\Program Files\AutoHotkey\Compiler\Ahk2Exe.ahk" /out "C:\Program Files\AutoHotkey\Compiler\Ahk2ExeH.exe" /bin [b]"BINWITH"[/b]
I mean almost every Ahk2Exe.exe/AutoHotKey.exe and Unicode X-bits.bin/AutoHotkeySC.bin I found on forums and github.
My scripts are running as .ahk, without issues. I cant understand why #DllImport is not recognized, I have no clue of where it can be internally called and why it isnt included when compiling.