for loop is not showing a message box

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
mexican scientist
Posts: 33
Joined: 02 Jul 2020, 21:55

for loop is not showing a message box

Post by mexican scientist » 01 Feb 2023, 00:14

Code: Select all

for x in 10 to 100 {
MsgBox % "x is: " x
}
what's wrong?

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

Re: for loop is not showing a message box

Post by mikeyww » 01 Feb 2023, 00:45

Wrong language. This one is AutoHotkey. :arrow: Loop

User avatar
boiler
Posts: 16931
Joined: 21 Dec 2014, 02:44

Re: for loop is not showing a message box

Post by boiler » 01 Feb 2023, 04:01

Probably because OP also got this from ChatGPT. This is why code produced by AI bots is not allowed on the forum. It produces nonsense that isn’t even a useful starting point.

@mexican scientist — Start by looking at the AHK documentation rather than wasting the forum members’ time with the output of a tool that doesn’t even follow a language’s syntax rules. It will be obvious when code produced by a bot is posted because it will have clear indications that no AHK coder would have written it — like what you just posted — so don’t do it.

Post Reply

Return to “Ask for Help (v1)”