VSCode doesn't like particular ahk file(?)
Posted: 25 Mar 2024, 15:22
Has anyone else run into this? It's noteworthy that my ahk scripts are all set up as "portable" apps, with the ahk and the exe having the same name, in the same parent folder.
I use essentially this same setup for a different script in the same folder and it works fine. One particular ahk file won't open though. I don't get the 'Catch' message, it just doesn't open. If I use a different editor, it works. I tried doing a "save as" to make sure the ahk file is saved as v2. Also, the ahk file does open normally via double-clicking file, via 'Open' command in VSCode, and via JumpList. It just doesn't work with a Run command in a script (like below).
Strange....
I use essentially this same setup for a different script in the same folder and it works fine. One particular ahk file won't open though. I don't get the 'Catch' message, it just doesn't open. If I use a different editor, it works. I tried doing a "save as" to make sure the ahk file is saved as v2. Also, the ahk file does open normally via double-clicking file, via 'Open' command in VSCode, and via JumpList. It just doesn't work with a Run command in a script (like below).
Strange....
Code: Select all
!+l::
EditThisLog(*)
{ soundBeep
thisScript := StrReplace(A_ScriptFullPath, ".exe", ".ahk")
Try
Run(MyAhkEditorPath " " thisScript)
Catch
msgbox 'cannot run ' thisScript
}