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

Migrating a modified gdl in an existing drawing

Anonymous
Not applicable
Hello :
I've just posted this. However, it appears I've sent the message to myself ! So here it is again, this time on the forum with luck.

Given : gdl.1 and drawing.1 containing multiple instances of gdl.1, many with different parameters.

I want to modify the gdl code.
1 I save a copy of gdl.1 to gdl.2
2 Modify gdl.2, test and save it.

I understand gdl.2 now has a different internal ID.

How do I tell ArchiCAD to use gdl.2 in drawing.1 in place of gdl.1?

i.e. with no changes to any of the existing objects in the drawing?
3 REPLIES 3
alemanda
Advocate
maybe one by one ...
AC27 latest hotfix

Win 10 Pro 64bit

Double XEON 14 CORES (tot 28 physical cores)

32GB RAM - SSD 256GB - Nvidia Quadro K620

Display DELL 25'' 2560x1440

www.almadw.it
Barry Kelly
Moderator
Yes, because you have created a brand new GDL2 object you will need to select each GDL1 object, open the settings dialogue, browse for GDL2 and CTRL+ALT (inject) the existing parameters into GDL2 to pass on the parameters.
You will have to do this one by one.

Otherwise what you could have done is 'SAVE' the object script instead of 'SAVE AS'.
This would update all your existing objects automatically with the new code.

You could now COPY the code from GDL2 and paste it back in GDL1 and then 'SAVE'.

Updating and saving the original object will affect all instances of that object in all files where the library containing that object is loaded.
So if you want to change all objects keeping there original settings then SAVE is the way to go.

You do have to be a little careful that the changes you make in the code don't break the objects.
If you add new parameters remember they won't be in the already placed instances so will use the defaults you sav in the amended object.

Something else you can look into is "Migrating" an object form one to another.
So you can have the original GDL1 migrate to the new GDL2 object.
It is possible to alter the values of new parameters in GDL2 based on values of old parameters in GDL1 or pass on the parameters as they were.
It is a bit more of an advanced GDL method so I wouldn't try to understand it unless you know what you are doing.
I don't think there is much documentation on it - I learnt by looking at the script of objects in the migration libraries.
You also need to delete GDL1 from your loaded library in order for GDL2 to automatically replace it - otherwise placed instances will just stay as they were.

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
Hello Barry :
Thank you for your detailed reply.

It may be migration is the way to go. I tend to make quite extensive changes to my gdl objects as I gain experience and think of new ways to do things.
And of course old files now show lots of green dots.

I can copy and paste the code easily enough. However, I also make changes to the parameter page. And there are lots of custom parameters. I guess those can't be copied easily except by saving a copy of the file.

And of course working on the original document is a bad idea if one is making extensive changes to the code. Or in my case, even minor ones !

I'll do some experimenting.

Thank you again.

Regards : Hubert Wagner
France