VS Code: New AHK File Issue

Scripting and setups with Visual Studio Code (vscode) and AutoHotkey.
marypoppins_1
Posts: 61
Joined: 28 Oct 2020, 02:58

VS Code: New AHK File Issue

Post by marypoppins_1 » 03 May 2021, 12:57

Hey,
I was wondering if someone knows the reason for the ahk template not always working. So basically, when I right click anywhere and make a new ahk script, it works perfectly and uses the custom "template" from the Template.ahk. However, when I make a new ahk file using Visual Studio Code, it uses a weird template and I wasn't able to locate it anywhere. I attached the picture below. If someone knows how we can change the template used by VSC it would make my day.
Thank you
Attachments
Code_LU4h0qvm11.png
Code_LU4h0qvm11.png (6.17 KiB) Viewed 3857 times

marypoppins_1
Posts: 61
Joined: 28 Oct 2020, 02:58

Re: VS Code: New AHK File Issue

Post by marypoppins_1 » 03 May 2021, 14:02

Hmm, so after some digging I found out that this was caused by the AHK Plus Plus extension by Mark Weimer. However, when I disable the extension and make a new ahk file it's empty and not using the "template".

User avatar
joedf
Posts: 8940
Joined: 29 Sep 2013, 17:08
Location: Canada
Contact:

Re: VS Code: New AHK File Issue

Post by joedf » 04 May 2021, 11:29

If you may, I think reporting this bug here would be helpful :thumbup: :
https://github.com/mark-wiemer/vscode-autohotkey-plus-plus/issues
Image Image Image Image Image
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]

marypoppins_1
Posts: 61
Joined: 28 Oct 2020, 02:58

Re: VS Code: New AHK File Issue

Post by marypoppins_1 » 06 May 2021, 13:11

Alright will do. Thanks

Rightclick
Posts: 2
Joined: 11 Jun 2018, 16:05

Re: VS Code: New AHK File Issue

Post by Rightclick » 01 Feb 2023, 13:35

You can set whatever template you like in settings: "Snippets: Configure User Snippets".
See details here: https://github.com/vscode-autohotkey/ahkpp/blob/main/docs/TemplateSnippet.md

User avatar
Curdflappers
Posts: 11
Joined: 13 Nov 2020, 03:18
Contact:

Re: VS Code: New AHK File Issue

Post by Curdflappers » 07 Feb 2023, 22:59

Yep, great callout Rightclick. Happy to answer any further questions you have about the extension :)

Post Reply

Return to “Visual Studio Code”