2022-02-05 08:30 PM - edited 2022-02-05 09:24 PM
This is happening to me rather often, and drives me crazy with error messages like "missing comma at parameter list" (as in this case) and such, until I realize what is going on. At first I copy-paste the script (select all, copy, paste) onto a text editor, check it there, give up in despair and close the object (the placed instances display as error dots), so I open the object again to find some funny “new” text appears that was not showing before (I know, because I had copy-pasted all into the text editor), in this case the last two characters, p".
[A red flag may be some empty lines that appear at the end of the text pasted to the text editor, which were not there in the script (at first I thought I was being sloppy, then I started checking), although I have only noticed this recently and haven't checked its consistency.]
2022-02-05 10:56 PM
Never had this issue.
Are you using CMD or Ctrl a to select all?
When I select with the cursor I sometimes manage to miss select
2022-02-06 12:19 AM
Select All.
2022-02-06 12:54 PM
In the past years I had many strange script changes that drove me to despair, they were even more extreme than you described.
I could not find a cause for this.
Graphisoft had no reasonable explanation for it either.
Sometimes it helped to select the text completely, copy it and paste it into a text editor, and then copy it back again, but that is no patent remedy.
Most of the time it helped a bit to restart Archicad if the problem occurred several times in a row.
2022-02-06 01:27 PM
Latest example, right now. “Inconsistent types of expression at Line 3” (a simple value list). This time I took a screenshot before closing (in top image, green is Select All text highlight). Close, reopen, mess.
Adding text to the top of the script may be one of the triggers.
2022-02-07 01:45 AM
I have noticed random errors in scripts, text in wrong places and definitely not as I typed it.
I always script in the oldest version we use (currently 20), so I rarely script in the latest versions.
But I have noticed this problem starting to appear - never happened in version 18.
I haven't pinned down the cause but have noticed it can depend on whether you work in the script in the main object dialogue window or the pop-out script window.
I usually work in the pop-out script
In fact if you get an error and compare the two, you will see they are not the same.
It seems to happen most often when copy & paste is used - looks good where you are working but not in the alternate script window.
Barry.
2022-02-20 01:58 PM
Right now, on AC25. Working on the main object window. Mystery error…
close, reopen, surprise.
2022-02-24 01:13 PM - edited 2022-02-24 11:51 PM
[Following Barry’s idea of comparing main window with pop-out window:] Type, Save, error warning, Save anyway, open pop-out, compare. [Inline image is not working for me and the attachment will be legible.]
This is becoming a very serious pain, it is not over in one pass, whack-a-mole scripting. AC25 INT on OS Monterey, but I've seen it across at least a couple other versions and MacOSs.
2022-02-24 05:01 PM
I liked your post - although I obviously don't like what is happening.
I can't understand how the two views of the same script can be different.
It is very annoying although (touch wood) it hasn't happened to me for a while which is why I have not posted an example.
Thanks for doing that.
Barry.
2022-02-24 05:21 PM - edited 2022-02-25 02:05 PM
I have uploaded images often, including three times in this thread. It was just not working when I tried. Right now it is not expanding the image when I click on it. Whatever.