Libraries & objects
About Archicad and BIMcloud libraries, their management and migration, objects and other library parts, etc.

Change 2D sybol of AC light

Anonymous
Not applicable
I'm trying to figure out how to change the 2D symbol of a copy of a stock AC light.

Original 2d-1.png
9 REPLIES 9
Anonymous
Not applicable
and....
Original 2d-2.png
Barry Kelly
Moderator
The problem is you are drawing your object in the 2D symbol window.
This is fine but if there is any script in the 2D script then that will be used and not the 2D symbol you have drawn.
You will need to comment out all of the 2D script if you don't want to use it or use the FRAGMENT2 command to access what has been drawn in the 2D symbol window.
Barry.
One of the forum moderators.
Versions 6.5 to 27
i7-10700 @ 2.9Ghz, 32GB ram, GeForce RTX 2060 (6GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11
Anonymous
Not applicable
I've tried ! commenting out all the lines in the 2D script which makes the stock 2D floor plan view go away, but my 2d symbol does not show.
So I looked in the GDL reference guide and found the Fragment2 command.
However in trying what I thought were all the variations shown, I kept getting errors when I did a check script.
Fragment-1.png
Anonymous
Not applicable
and...
Some of the other variations of the Fragment2 command I tried got different warnings, but no matter what I tried, no go, except for one error message said when I went to save anyway, was that if I continued it would not use 2D script, and use my 2D symbol, but it didn't.
Fragment-2.png
rocorona
Booster
lec1212 wrote:
I've tried ! commenting out all the lines in the 2D script which makes the stock 2D floor plan view go away, but my 2d symbol does not show.
Almost sure, you left something there. If the GDL interpreter finds anything "readable" in the 2D Script, will try to use it instead of the 2D Drawing.
lec1212 wrote:
So I looked in the GDL reference guide and found the Fragment2 command.
However in trying what I thought were all the variations shown, I kept getting errors when I did a check script.

You copyied the command as it is on the manual, but you didn't read the "CONVENTIONS USED IN THIS BOOK" paragraph (p.13). You must write as in syntax only the words in capital letters. Generally, the others are to be substituted by values (or variables)
So use:
FRAGMENT2 ALL, 0
or
FRAGMENT2 ALL, 1
(with the first one the drawn elements retain their attributes, with the second one the current attributes of the object will be used)

In the other your post the error is generated by the comma between "FRAGMENT2" and "ALL"

To stop the interpreter after it executes the FRAGMENT2 command, add a row with the END command, or simply delete all.
_________________

--Roberto Corona--
www.archiradar.com
AC18 - ITA full on Win10
_________________
_________________
Anonymous
Not applicable
rocorona wrote:
lec1212 wrote:
I've tried ! commenting out all the lines in the 2D script which makes the stock 2D floor plan view go away, but my 2d symbol does not show.
Almost sure, you left something there. If the GDL interpreter finds anything "readable" in the 2D Script, will try to use it instead of the 2D Drawing.

I had looked up and down the 2D script 3 times only not ! commenting out lines that were blank, but must have missed something I guess.
lec1212 wrote:
So I looked in the GDL reference guide and found the Fragment2 command.
However in trying what I thought were all the variations shown, I kept getting errors when I did a check script.

You copyied the command as it is on the manual, but you didn't read the "CONVENTIONS USED IN THIS BOOK" paragraph (p.13). You must write as in syntax only the words in capital letters. Generally, the others are to be substituted by values (or variables)
So use:
FRAGMENT2 ALL, 0
or
FRAGMENT2 ALL, 1
(with the first one the drawn elements retain their attributes, with the second one the current attributes of the object will be used)

In the other your post the error is generated by the comma between "FRAGMENT2" and "ALL"

To stop the interpreter after it executes the FRAGMENT2 command, add a row with the END command, or simply delete all.
Anonymous
Not applicable
lec1212 wrote:
rocorona wrote:
lec1212 wrote:
I've tried ! commenting out all the lines in the 2D script which makes the stock 2D floor plan view go away, but my 2d symbol does not show.
Almost sure, you left something there. If the GDL interpreter finds anything "readable" in the 2D Script, will try to use it instead of the 2D Drawing.

I had looked up and down the 2D script 3 times only not ! commenting out lines that were blank, but must have missed something I guess.
lec1212 wrote:
So I looked in the GDL reference guide and found the Fragment2 command.
However in trying what I thought were all the variations shown, I kept getting errors when I did a check script.

You copyied the command as it is on the manual, but you didn't read the "CONVENTIONS USED IN THIS BOOK" paragraph (p.13). You must write as in syntax only the words in capital letters. Generally, the others are to be substituted by values (or variables)
oooppsss re. p13
So use:
FRAGMENT2 ALL, 0
or
FRAGMENT2 ALL, 1
(with the first one the drawn elements retain their attributes, with the second one the current attributes of the object will be used)

In the other your post the error is generated by the comma between "FRAGMENT2" and "ALL"

To stop the interpreter after it executes the FRAGMENT2 command, add a row with the END command, or simply delete all.


Tried both of the Fragment2 commands you listed to see the difference (and the END).
Worked perfectly
Thank you Roberto
Good thing I don't write code for a living:-)
Take care.
Be safe out there.
David Maudlin
Rockstar
lec1212 wrote:
rocorona wrote:
lec1212 wrote:
I've tried ! commenting out all the lines in the 2D script which makes the stock 2D floor plan view go away, but my 2d symbol does not show.
Almost sure, you left something there. If the GDL interpreter finds anything "readable" in the 2D Script, will try to use it instead of the 2D Drawing.

I had looked up and down the 2D script 3 times only not ! commenting out lines that were blank, but must have missed something I guess.
An easier way to do this is to select the Script Window, then command Select All, then command Comment (this command is in the Edit menu when editing a library part).

David
David Maudlin / Architect
www.davidmaudlin.com
Digital Architecture
AC27 USA • iMac 27" 4.0GHz Quad-core i7 OSX11 | 24 gb ram • MacBook Pro M3 Pro | 36 gb ram OSX14
Anonymous
Not applicable
Thanks for the tip David.