Hi
I would like to access an element group that already exists in the model space.
When selecting the element group, I get the element (for example a line) that is part of the element group.
With GetParent, I can access the element group.
At least, this is what I can see when querying the element type.
Below, I have included the code lines.
elemente = self.post_element_selection.GetSelectedElements(self.coord_input.GetInputViewDocument())
ele_ad = AllplanElementAdapter.BaseElementAdapter(elemente)
line = AllplanBaseElements.GetElement(ele_ad) # get's the Line-Element that was selected
parent = AllplanElementAdapter.BaseElementAdapterParentElementService.GetParentElement(ele_ad)
type = parent.GetElementAdapterType().GetTypeName() # 'ElementGroup_TypeUUID'
I would like to be able to read all the elements of the element group so that I can use their geometry.
However, I don’t understand how this can be done.
Does anyone have a good idea on how to achieve this?
Kind regards,
Diego