Machsupport Forum
Mach Discussion => Mach4 General Discussion => Topic started by: TTalma on March 10, 2024, 05:37:23 PM
-
I was editing a screen and added a button. I set the click script to call macro 'm500', and typed it in that way. It should be 'm500()'. But now when I load the screen it gives the error:
Lua: Script error during pre compilation
c:\mach4hobby\Screenscript.Lua:861'Syntex error near 'end'
I tried removing the line from Screenscript.lua, (I did remove the read-only status). Saved the file and and verified my change was saved. But when I restart Mach 4 I get the same error, and when I check Screenscript.lua the line with the error is back.
How do I fix this error?
-
if you can't fix the error replace the wx4.set file in the screen sub-folder with the original file. That will put all the screen scripts back as they were when you installed. If you've made a lot of modifications they will of course be lost.. usually I save the last screen set file that worked when I start to make changes so if something doesn't work, and won't let Mach4 run, I can at least revert back to the last file that did. :o
-
Start mach4 in the screen editing mode. /e
/e is optional -- start the GUI in screen edit mode.
/f is optional -- start in full screen mode
/m is optional -- remove the menu.
-
Thank you the /e option worked!
Other than my M code files and other files I've created which file s should I back up?
-
/e is optional -- start the GUI in screen edit mode.
As stated before this works.
Also if you open the MACH4 loader for the C folder on newer versions you'll see an option for
"Open screen in edit mode"
It should be a checkmark box at the bottom of the loader window.