Archicad Python API
About automating tasks in Archicad using the Python API.
SOLVED!

Gross, Net and Conditional Areas with Python API

AxelL
Participant

Hi! 

I am using the Python API ACConnection to access and extract the properties of elements in my .pln file. I use the built-in property guide

https://gdl.graphisoft.com/reference-guide/built-in-property-guide to assign the names of the properties to extract, so for example my list looks like this:
propertyUserIds = [
    act.BuiltInPropertyUserId("General_ElementID"),
    act.BuiltInPropertyUserId("General_Height"),
    act.BuiltInPropertyUserId("General_SurfaceArea"),
    act.BuiltInPropertyUserId("General_NetEdgeSurfaceArea"),
    act.BuiltInPropertyUserId("General_NetVolume"),
    act.BuiltInPropertyUserId("General_GrossVolume"),
    act.BuiltInPropertyUserId("General_ConditionalVolume") . . .
]

My question is if that is the entire list of all the properties that can be extracted for all elements via Python? I could not find e.g. net/gross areas and thought it was overall a bit unclear sometimes what different properties mean for different elements. Do you have some advice on interpretation, or good resources for the Python API and extracting all properties from elements in a file? Would be much appreciated!

 

Best regards,

Axel

 

Operating system used: Windows

1 ACCEPTED SOLUTION

Accepted Solutions
Solution
RobPhill33
Booster

No, use the GetAllPropertyNames() method from the Commands class to generate a list of all the property names.  You'll have to extract the names with list comprehension or something if you want to isolate them, but you get the idea. 

 

Python API Wrapper

https://archicadapi.graphisoft.com/archicadPythonPackage/archicad.releases.ac27.html 

View solution in original post

2 REPLIES 2
Solution
RobPhill33
Booster

No, use the GetAllPropertyNames() method from the Commands class to generate a list of all the property names.  You'll have to extract the names with list comprehension or something if you want to isolate them, but you get the idea. 

 

Python API Wrapper

https://archicadapi.graphisoft.com/archicadPythonPackage/archicad.releases.ac27.html 

Ah excellent, thank you! 

Setup info provided by author