Getting this error - Function calls require a space or "( Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
gauravkhurana
Posts: 2
Joined: 19 May 2022, 08:28

Getting this error - Function calls require a space or "(

Post by gauravkhurana » 19 May 2022, 08:43

I created a script called a.ahk and it has just one line. This started happening since i moved to a new PC.
Script is working fine on my other computer but with the version i recently installed.. its failing.

F12::Send,#+s

While running the script i am getting below error

---------------------------
a.ahk
---------------------------
Error: Function calls require a space or "(". Use comma only between parameters.

Specifically: Send,#+s

Line#
---> 001: {

The program will exit.
---------------------------
OK
---------------------------

User avatar
mikeyww
Posts: 26856
Joined: 09 Sep 2014, 18:38

Re: Getting this error - Function calls require a space or "(  Topic is solved

Post by mikeyww » 19 May 2022, 08:55

Welcome to this AutoHotkey forum!

As I understand it, AHK version 2 has transformed commands into functions.

Use AHK version 1.x. The latest is 1.1.34.02.

Or:

Code: Select all

F12::Send "#+s"

gauravkhurana
Posts: 2
Joined: 19 May 2022, 08:28

Re: Getting this error - Function calls require a space or "(

Post by gauravkhurana » 19 May 2022, 09:17

Thanks a lot this has helped me.

Strangely i have 1.1.34 version and

Still i need to replace , with "

Is there a place where i can see all the changes at one place as i think i would need to change my all scripts.

User avatar
mikeyww
Posts: 26856
Joined: 09 Sep 2014, 18:38

Re: Getting this error - Function calls require a space or "(

Post by mikeyww » 19 May 2022, 12:22

You can have both versions and be running the other version without intention (e.g., by file association). https://www.autohotkey.com/docs/AHKL_ChangeLog.htm

v2: https://lexikos.github.io/v2/docs/v2-changes.htm

Post Reply

Return to “Ask for Help (v1)”