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

Python and Morph

Joze Marinko
Participant

I want pull out areas from morph.

code is:

from Archicad import ACConnection

conn = ACConnection.connect()
assert conn

acc = conn.commands
act = conn.types
acu = conn.utilities

 

klasifikacijaGP = acu.FindClassificationItemInSystem('Urbanizem','Gradbena parcela')
elementiGP = acc.GetElementsByClassification(klasifikacijaGP.classificationItemId)
obmocjeGP = acu.GetUserDefinedPropertyId('Gradbena parcela','Območje')

povrsinaGP = acu.GetBuiltInPropertyId('Morph_FloorPlanAreaByStory')

obmocjeSeznamGP = [(acc.GetPropertyValuesOfElements(elementiGP,[obmocjeGP])[i].propertyValues[0].propertyValue.value) for i in range(len(elementiGP))]
povrsinaSeznamGP = [(acc.GetPropertyValuesOfElements(elementiGP,[povrsinaGP])[i].propertyValues[0].propertyValue.value) for i in range(len(elementiGP))]


In variable "povrsinaSeznamGP" I expect list of areas 😞 But I got error message. What is wrong? 

2 REPLIES 2

poco2013
Mentor

FYI:

Graphisoft reported this issue as a bug. You can not obtain the area for all stories with this function. It will be fixed in a future release -- if they get to it (IMHO)?

Gerry

Windows 10 - Visual Studio 2019; ArchiCAD 26

Gerry, thanks for replay. 

Still looking?

Browse more topics

Back to forum

See latest solutions

Accepted solutions

Start a new discussion!