We value your input!
Please participate in Archicad 28 Home Screen and Tooltips/Quick Tutorials survey

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

Pulling Project Info into GDLs

Anonymous
Not applicable
Hello,

My name is Jason Roesler and I am the Technical Drafting Manager for a local home builder in Calgary, AB, Canada. We have been using ArchiCAD since 2008 but honestly haven't been using it to its full potential. I am currently in the middle of overhauling our templates and rebuilding our library.

As a home builder we produce ~450 sets of drawings every year and they all basically go through the same steps and approval process. With that said I am currently working on a simple GDL script that will produce a 2 line signature bar when the Project Status has the text "PERMIT". I have done some looking around and found that you can reference <PROJECTSTATUS> in the GDL script it will product the text in the object but if you try to us it as a variable it doesn't give the desired results.

My latest though is to somehow have the GDL Parameters auto fill a variable, say "_status", that uses the <PROJECTSTATUS> as a reference but I have no idea on where to start with that. Which when the text is typed in the script below works flawlessly but getting it to auto fill is my biggest roadblock right now.

Anyone have any thoughts?


PEN 1
FILL 85

DEFINE STYLE _toptext "Arial Narrow", 8 * 25.4/72 / GLOB_SCALE, 7, 0
DEFINE STYLE _bottomtext "Arial Narrow", 8 * 25.4/72 / GLOB_SCALE, 1, 0

HOTSPOT2 0", 0"

IF _status='PERMIT' THEN

	SET STYLE _toptext
	TEXT2 0", 0", 'CUSTOMER SIGNATURE: _________________________ // _________________________'
	
	SET STYLE _bottomtext
	TEXT2 0", 0", 'SALES SIGNATURE: _________________________'

ENDIF

1 REPLY 1
Barry Kelly
Moderator
Unfortunately Project Info values are autotext fields and while they can be used in 2D scripts their values can not be read in GDL.
There seems to be a work around by exporting the Project Info to a XML file and then reading that into the GDL script.

http://archicad-talk.graphisoft.com/viewtopic.php?t=30655&postdays=0&postorder=asc&highlight=project...

But I would say it would be easier to just create an object that you manually place on the plan when you need it.

I guess it could be done through Library Globals in the Model View Options but to me that (once set up) will be the same amount of work as placing an object manually.
It still won't be linked with the Project Info.
You would have to go into the MVO and tick a box that says project status is 'Permit' - then your GDL object could react to that (via Library Globals).
You might just as well select an object and place it or have the object with a parameter for project status as it seems you have done already.

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