Hello!
I am trying to automate the making and analysis of a simple steel structure through Dynamo and Robot. However, to conduct seismic analysis, it is required to define stories. I have tried to find resources that could help me understand what I'm missing but I can't find a solution.
Any help or advive would be greatly appreciated!
Solved! Go to Solution.
Solved by Stephane.kapetanovic. Go to Solution.
hi @evyaw12
first try reading the "Robot API 2024" guide on page 1049 about the methods of the IRobotStoreyMngr interface
use Create2 or Create2Ex.
Sub CreateStorey()
Dim RobApp As RobotApplication
Set RobApp = New RobotApplication
Dim Storeys As RobotStoreyMngr, Storey As RobotStorey, StoreyNumber As Long
Dim StoreyName As String, TopLevel As Double, ListObjects As String, ColorIndex As Long
Set Storeys = RobApp.Project.Structure.Storeys
Storeys.BaseLevel = 0
' Method Create2
StoreyName = "MyStoreyName": TopLevel = 5.2: ListObjects = "1to10 20to30": ColorIndex = 1
StoreyNumber = Storeys.Create2(StoreyName, TopLevel)
' Method Create2Ex
StoreyNumber = Storeys.Create2Ex(StoreyName, TopLevel, ListObjects, ColorIndex)
' Access to a storey
Set Storey = Storeys.Get(StoreyNumber)
With Storey
.Objects = ListObjects: .Color = ColorIndex
End With
Set RobApp = Nothing
End Sub
Best Regards
Can't find what you're looking for? Ask the community or share your knowledge.