cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Streamline your workflows and master BIM coordination! Program starts April 28!

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

Macro basics - share info

Not applicable
Hi everyone,

I'm looking for information on how to work with macros:
- where are the existing one stored
- where to save new ones
- how to open and edit existing ones
- list of parameters that could be used from a macro

Unfortunately I can't find any information on that, only info is to call a macro and thats it...

Please share links on how to deal with macros

PS. For example I need to modify the basic slab opening object which for some reason is one big macro named "slabOpeningSymbol_m" and called in the Master Script:
EPS = 0.0001

if GLOB_SCRIPT_TYPE <> 7 & GLOB_SCRIPT_TYPE <> 8 then
	call "slabOpeningSymbol_m" parameters all iSymbolType		= 1
endif
and thats it, no more code in the object.
So how do I do that, where is the code for the opening ?

Thanks !
4 REPLIES 4
Hi,

The macros are stored "somewhere" in the loaded library - hard to determine, depends on the library designer.

So to open: either use "open by subtype" command located in the GDL edit toolbar (activate it if not activated in Your UI)
but If You have a script calling such macro - just select its name and hit "CTRL+SHIFT+O"

there are no parameters restrictions...the parameters can be transered like after end command for example or via request.

All documented (some better some worse in GDL documentation)

Best Regards,
Piotr Dobrowolski
Laszlo Nagy
Community Admin
Official documentation:

http://gdl.graphisoft.com/gdl-docs/gdl-guide/chapter-11-control-statements/macro-objects/

http://gdl.graphisoft.com/gdl-docs/basic-technical-standards/writing-macros/

All results returned for the search term "macro" from gdl.graphisoft.com:

https://www.google.hu/search?sourceid=chrome-psyapi2&ion=1&espv=2&ie=UTF-8&q=macro%20site%3Agdl.grap...
Loving Archicad since 1995 - Find Archicad Tips at x.com/laszlonagy
AMD Ryzen9 5900X CPU, 64 GB RAM 3600 MHz, Nvidia GTX 1060 6GB, 500 GB NVMe SSD
2x28" (2560x1440), Windows 10 PRO ENG, Ac20-Ac28
Not applicable
Thanks everyone !

The key was to use the "Open by subtype".

Next question:

Typical slab opening object names "Floor Opening Symbol" found in:
Archicad Library > BASIC LIBRARY > 1.7 2D Elements > graphic Symbols

has no code itself, only parameters and the call function in "Master":
EPS = 0.0001
if GLOB_SCRIPT_TYPE <> 7 & GLOB_SCRIPT_TYPE <> 8 then
	call "slabOpeningSymbol_m" parameters all iSymbolType		= 1
endif

Does anyone have an idea what is the reason to keep the code inside the macro and not in the object itself ?

I would understand thsi if this macro would be used inside any other object but I don't know any other slab opening objects .

So... last question:
Is there a way to discover in which objects is a particular macro used ?
The reason is the object (the macro) is a whole object...and the "real" clickable object is just changing the parameters to suit the needs...and maybe it is used in more objects (but it is not possible automatically to find the all objects using it)
Another example of such objects are all doors (almost) - they "only" call the "superdoor" object with some parameters (and soome are not user accesible normally) eg: the single door...double...sidelights etc.

Best Regards,
Piotr