(API) FINITE ELEMENT SELECTION BY FLOOR

(API) FINITE ELEMENT SELECTION BY FLOOR

Anonymous
Not applicable
730 Views
4 Replies
Message 1 of 5

(API) FINITE ELEMENT SELECTION BY FLOOR

Anonymous
Not applicable

Hi,

 

is there a way of selecting finite elements on a floor?

 

I've tried the following but it selects something else.

 

IRobotStoreyMngr currentStorey = robApp.Project.Structure.Storeys.Get(1).Name;
RobotSelection felemSelection = robApp.Project.Structure.Selections.CreateByStorey(IRobotObjectType.I_OT_FINITE_ELEMENT, currentStorey);
0 Likes
Accepted solutions (1)
731 Views
4 Replies
Replies (4)
Message 2 of 5

Rafal.Gaweda
Autodesk Support
Autodesk Support
Accepted solution

it seems this works correctly:

 

RobApp.Project.Structure.Selections.CreateByStorey(I_OT_PANEL, "Story 1")

so from panel select FEs



Rafal Gaweda
Message 3 of 5

Anonymous
Not applicable

But in this way it is not possible to get Finite element's particular object data (i.e nodes)

 

 

Because the selection is panel objects. 

 

 

IRobotCollection panelCollection = robApp.Project.Structure.Objects.GetMany(panelSelection);
var PL = panelCollection.get(1); -> returns a panel object
string felems = PL.FiniteElems; -> returns a string of Finite elements

 

It would be nice to use like below to get the nodes.

 

RobotSelection felemSelection = robApp.Project.Structure.Selections.CreateByStorey(IRobotObjectType.I_OT_FINITE_ELEMENT, "Story 1");

IRobotCollection felemCollection = (IRobotCollection)robApp.Project.Structure.FiniteElems.GetMany(felemSelection);

RobotFiniteElement FE = felemCollection.get(1);

RobotFiniteElementNodes nodes = FE.Nodes;

int nodeCount = nodes.Count;
nodes.Get(1);
nodes.Get(2);
nodes.Get(3);

 

 

However it seems that its not possible now...?

 

0 Likes
Message 4 of 5

Rafal.Gaweda
Autodesk Support
Autodesk Support
robApp.Project.Structure.Selections.CreateByStorey(IRobotObjectType.I_OT_NODE, "Story 1")

 

 

This should be the easiets way, but unfortunately it does not work (like FE selection) by story 



Rafal Gaweda
Message 5 of 5

Rafal.Gaweda
Autodesk Support
Autodesk Support

Getting FE nodes

 

Dim FEData As RobotFiniteElementData

Dim x As Double, y As Double, z As Double ' nodal coordinates to return
For i = 1 To 24 Set FEData = RobApp.Project.Structure.FiniteElems.Get(i) For j = 1 To FEData.NodeCount NodeNumber = FEData.GetNode(j, x, y, z) Next j Next i

 



Rafal Gaweda
0 Likes