Export results ARSA via API

Stephane.kapetanovic
Mentor

Export results ARSA via API

Stephane.kapetanovic
Mentor
Mentor

A copy of a popular discussion thread from 2012.

msg 20

Sub extraction_resultats_cas()

Range("A13", "F25000").Clear
Range("B5").Clear

Set RobApp = New RobotApplication

If Not RobApp.Visible Then
    Set RobApp = Nothing
    MsgBox "Open Robot and load Model", vbOKOnly, "ERROR"
    Exit Sub
Else
    If (RobApp.Project.Type <> I_PT_FRAME_3D) And (RobApp.Project.Type <> I_PT_SHELL) Then
        MsgBox "Structure Type should be FRAME 3D or SHELL", vbOKOnly, "ERROR"
        Exit Sub
    End If
    Cells(5, 1) = "Project"
    Cells(5, 2) = RobApp.Project.Name

'selection des barres

'If CheckBox1 = True Then

'Dim BarCol As RobotBarCollection
'Set BarCol = RobApp.Project.Structure.Bars.GetAll

'Else

    Dim RSelection As RobotSelection
    Set RSelection = RobApp.Project.Structure.Selections.Get(I_OT_BAR)
    Dim BarCol As RobotBarCollection
    Set BarCol = RobApp.Project.Structure.Bars.GetMany(RSelection)
    Dim num_bar As String
    
'   If (BarCol.Count = 0) Then   c'est un test de selection du modele
'       If (MsgBox("No bars selected in Robot. Do you want to import results for all bars?", vbYesNo, "Warning") = vbYes) Then
num_bar = Cells(8, 2)
    If num_bar = "" Then
        If (MsgBox("Pas de numéro de barres indiqué ! Voulez-vous selectionner toutes les barres?", vbYesNo, "Warning") = vbYes) Then
            RSelection.FromText "all"
            RSelection.AddText "tous"
            Set BarCol = RobApp.Project.Structure.Bars.GetMany(RSelection)
        Else
            Set BarCol = Nothing
            Exit Sub
        End If
    ' ajout condition pour rentrer soi-même les numéros de barres
    Else
    RSelection.FromText num_bar
    Set BarCol = RobApp.Project.Structure.Bars.GetMany(RSelection)
    End If

'End If

    
    Set RSelection = RobApp.Project.Structure.Selections.Get(I_OT_CASE)
    Dim CaseCol As RobotCaseCollection
    Set CaseCol = RobApp.Project.Structure.Cases.GetMany(RSelection)
    Dim num_cas As String
    
 num_cas = Cells(9, 2)
    
'    If (CaseCol.Count = 0) Then
    If num_cas = "" Then
        If (MsgBox("Pas de cas ou combinaisons indiqué ! Voulez-vous importer les résultats de tous les cas ?", vbYesNo, "Warning") = vbYes) Then
            RSelection.FromText "all"
            RSelection.AddText "tous"
            Set CaseCol = RobApp.Project.Structure.Cases.GetMany(RSelection)
        Else
            Set CaseCol = Nothing
            Exit Sub
        End If
    Else
    RSelection.FromText num_cas
    Set CaseCol = RobApp.Project.Structure.Cases.GetMany(RSelection)
    End If
    
    Cells(9, 2) = RSelection.ToText
    
    NumberOfPoints = Int(Cells(10, 2).Value)
    
    If (NumberOfPoints < 2) Then
        MsgBox "Number of points along the bar must be greater or equal to 2", vbOKOnly, "Error"
        Exit Sub
    End If
    
'Sleep 10000
    
    Row = 12
'    Cells(Row, 1) = "Barre"
'    Cells(Row, 2) = "Noeud"
'    Cells(Row, 3) = "Cas (/ Composante)"
'
'     Cells(Row, 4) = "FX [kN]"
'     Cells(Row, 5) = "FZ [kN]"
'     Cells(Row, 6) = "MY [kN.m]"
     
     Cells(19, 9) = "Progression"
     
 For i = 1 To BarCol.Count
     Cells(20, 9) = Str(i) + " / " + Str(BarCol.Count)

     
     Dim RBar As RobotBar
     Set RBar = BarCol.Get(i)
     
     BarNumber = RBar.Number
     BarStr = Str(BarNumber)
     OriNodeStr = Str(RBar.StartNode)
     EndNodeStr = Str(RBar.EndNode)
     
     
     
     Dim BFD As RobotBarForceData
     Dim Icomp As Integer
     
     Dim BarForceServer As RobotBarForceServer
     Set BarForceServer = RobApp.Project.Structure.Results.Bars.Forces
     
     Dim Point As Double
     Dim Step As Double
     
     Point = 0#
     Step = 1# / (NumberOfPoints - 1)
     
For ii = 1 To NumberOfPoints

    For j = 1 To CaseCol.Count
        AT = CaseCol.Get(j).AnalizeType
     
        If AT <> I_CAT_COMB_CODE _
            And AT <> I_CAT_COMB _
            And AT <> I_CAT_COMB_NONLINEAR _
            And AT <> I_CAT_STATIC_LINEAR _
            And AT <> I_CAT_STATIC_NONLINEAR Then
                MsgBox "This macro works only for simple load cases, combinations and automatic combinations", vbOKOnly, "Error"
                Exit Sub
        End If
     
     UNC = CaseCol.Get(j).Number
     CaseStr = Str(UNC)
     If CaseCol.Get(j).Type = I_CT_CODE_COMBINATION Then  ' pour les combinaisons
          
          Dim CCount As Integer
          CCount = CaseCol.Get(j).Components.Count
          Dim StrCC As String
          StrCC = Str(CCount)
          
          If InStr(CaseCol.Get(j).Name, "+") <> 4 And InStr(CaseCol.Get(j).Name, "-") <> 4 And InStr(CaseCol.Get(j).Name, "+") <> 8 And InStr(CaseCol.Get(j).Name, "-") <> 8 Then
            For Icomp = 1 To CCount
                
                CompStr = " / " + Str(Icomp)
  
                    Row = Row + 1
          
                    If ii = 1 Then
                        Cells(Row, 1) = BarStr
                        Cells(Row, 2) = OriNodeStr
                        Cells(Row, 3) = CaseStr + CompStr
                    ElseIf ii = NumberOfPoints Then
                        Cells(Row, 1) = BarStr
                        Cells(Row, 2) = EndNodeStr
                        Cells(Row, 3) = CaseStr + CompStr
                    Else
                       Cells(Row, 1) = BarStr + Str(ii) + " /" + Str(NumberOfPoints) + " / " + CaseStr + CompStr
                     End If

                    Set BFD = BarForceServer.ValueEx(BarNumber, UNC, Icomp, Point)
         Cells(Row, 4) = BFD.FX * 0.001
         Cells(Row, 5) = BFD.FZ * 0.001
         Cells(Row, 6) = BFD.MY * 0.001

                    Set BFD = Nothing
          Next Icomp
          End If
     Else                                        ' pour les cas simples
         Row = Row + 1
         If ii = 1 Then
                        Cells(Row, 1) = BarStr
                        Cells(Row, 2) = OriNodeStr
                        Cells(Row, 3) = CaseStr
         ElseIf ii = NumberOfPoints Then
                        Cells(Row, 1) = BarStr
                        Cells(Row, 2) = EndNodeStr
                        Cells(Row, 3) = CaseStr
         Else
            Cells(Row, 1) = BarStr
            Cells(Row, 2) = Str(ii) + " /" + Str(NumberOfPoints)
            Cells(Row, 3) = CaseStr

         End If
         
         Set BFD = BarForceServer.Value(BarNumber, UNC, Point)
         Cells(Row, 4) = BFD.FX * 0.001
         Cells(Row, 5) = BFD.FZ * 0.001
         Cells(Row, 6) = BFD.MY * 0.001
         
         Set BFD = Nothing
         
     End If
     Point = Point + Step
      
      Next j
 Next ii

Next i
     
End If
Cells(19, 9) = ""
Cells(20, 9) = ""

End Sub

 

0 Likes
Reply
263 Views
3 Replies
Replies (3)

Stephane.kapetanovic
Mentor
Mentor

msg 22

Sub extraction_resultats_cas()

 

Range("A13", "F25000").Clear
Range("B5").Clear

Set RobApp = New RobotApplication

If Not RobApp.Visible Then
Set RobApp = Nothing
MsgBox "Open Robot and load Model", vbOKOnly, "ERROR"
Exit Sub
Else
' If (RobApp.Project.Type <> I_PT_FRAME_3D) And (RobApp.Project.Type <> I_PT_SHELL) Then
' MsgBox "Structure Type should be FRAME 3D or SHELL", vbOKOnly, "ERROR"
' Exit Sub
' End If
Cells(5, 1) = "Project"
Cells(5, 2) = RobApp.Project.Name

'selection des barres

'If CheckBox1 = True Then

'Dim BarCol As RobotBarCollection
'Set BarCol = RobApp.Project.Structure.Bars.GetAll

'Else

Dim RSelection As RobotSelection
Set RSelection = RobApp.Project.Structure.Selections.Get(I_OT_BAR)
Dim BarCol As RobotBarCollection
Set BarCol = RobApp.Project.Structure.Bars.GetMany(RSelection)
Dim num_bar As String

' If (BarCol.Count = 0) Then c'est un test de selection du modele
' If (MsgBox("No bars selected in Robot. Do you want to import results for all bars?", vbYesNo, "Warning") = vbYes) Then
num_bar = Cells(8, 2)
If num_bar = "" Then
If (MsgBox("Pas de numéro de barres indiqué ! Voulez-vous selectionner toutes les barres?", vbYesNo, "Warning") = vbYes) Then
RSelection.FromText "all"
RSelection.AddText "tous"
Set BarCol = RobApp.Project.Structure.Bars.GetMany(RSelection)
Else
Set BarCol = Nothing
Exit Sub
End If
' ajout condition pour rentrer soi-meme les numéros de barres
Else
RSelection.FromText num_bar
Set BarCol = RobApp.Project.Structure.Bars.GetMany(RSelection)
End If

'End If


Set RSelection = RobApp.Project.Structure.Selections.Get(I_OT_CASE)
Dim CaseCol As RobotCaseCollection
Set CaseCol = RobApp.Project.Structure.Cases.GetMany(RSelection)
Dim num_cas As String

num_cas = Cells(9, 2)

' If (CaseCol.Count = 0) Then
If num_cas = "" Then
If (MsgBox("Pas de cas ou combinaisons indiqué ! Voulez-vous importer les résultats de tous les cas ?", vbYesNo, "Warning") = vbYes) Then
RSelection.FromText "all"
RSelection.AddText "tous"
Set CaseCol = RobApp.Project.Structure.Cases.GetMany(RSelection)
Else
Set CaseCol = Nothing
Exit Sub
End If
Else
RSelection.FromText num_cas
Set CaseCol = RobApp.Project.Structure.Cases.GetMany(RSelection)
End If

Cells(9, 2) = RSelection.ToText

NumberOfPoints = Int(Cells(10, 2).Value)

If (NumberOfPoints < 2) Then
MsgBox "Number of points along the bar must be greater or equal to 2", vbOKOnly, "Error"
Exit Sub
End If

'Sleep 10000

Row = 12
' Cells(Row, 1) = "Barre"
' Cells(Row, 2) = "Noeud"
' Cells(Row, 3) = "Cas (/ Composante)"
'
' Cells(Row, 4) = "FX [kN]"
' Cells(Row, 5) = "FZ [kN]"
' Cells(Row, 6) = "MY [kN.m]"

Cells(19, 9) = "Progression"

For i = 1 To BarCol.Count
Cells(20, 9) = Str(i) + " / " + Str(BarCol.Count)


Dim RBar As RobotBar
Set RBar = BarCol.Get(i)

BarNumber = RBar.Number
BarStr = Str(BarNumber)
OriNodeStr = Str(RBar.StartNode)
EndNodeStr = Str(RBar.EndNode)



Dim BFD As RobotBarForceData
Dim Icomp As Integer

Dim BarForceServer As RobotBarForceServer
Set BarForceServer = RobApp.Project.Structure.Results.Bars.Forces

Dim Point As Double
Dim Step As Double

Point = 0#
Step = 1# / (NumberOfPoints - 1)

For ii = 1 To NumberOfPoints

For j = 1 To CaseCol.Count


AT = CaseCol.Get(j).AnalizeType

If AT <> I_CAT_COMB_CODE _
And AT <> I_CAT_COMB _
And AT <> I_CAT_COMB_NONLINEAR _
And AT <> I_CAT_STATIC_LINEAR _
And AT <> I_CAT_STATIC_NONLINEAR Then
MsgBox "This macro works only for simple load cases, combinations and automatic combinations", vbOKOnly, "Error"
Exit Sub
End If

UNC = CaseCol.Get(j).Number
CaseStr = Str(UNC)
If CaseCol.Get(j).Type = I_CT_CODE_COMBINATION Then ' pour les combinaisons

Dim CCount As Integer
CCount = CaseCol.Get(j).Components.Count
Dim StrCC As String
StrCC = Str(CCount)

If InStr(CaseCol.Get(j).Name, "+") <> 4 And InStr(CaseCol.Get(j).Name, "-") <> 4 And InStr(CaseCol.Get(j).Name, "+") <> 8 And InStr(CaseCol.Get(j).Name, "-") <> 8 Then
For Icomp = 1 To CCount

CompStr = " / " + Str(Icomp)

Row = Row + 1

If ii = 1 Then
Cells(Row, 1) = BarStr
Cells(Row, 2) = OriNodeStr
Cells(Row, 3) = CaseStr + CompStr
ElseIf ii = NumberOfPoints Then
Cells(Row, 1) = BarStr
Cells(Row, 2) = EndNodeStr
Cells(Row, 3) = CaseStr + CompStr
Else
Cells(Row, 1) = BarStr + Str(ii) + " /" + Str(NumberOfPoints) + " / " + CaseStr + CompStr
End If

Set BFD = BarForceServer.ValueEx(BarNumber, UNC, Icomp, Point)
Cells(Row, 4) = BFD.FX * 0.001
Cells(Row, 5) = BFD.FZ * 0.001
Cells(Row, 6) = BFD.MY * 0.001

Set BFD = Nothing
Next Icomp
End If
Else ' pour les cas simples
Row = Row + 1
If ii = 1 Then
Cells(Row, 1) = BarStr
Cells(Row, 2) = OriNodeStr
Cells(Row, 3) = CaseStr
ElseIf ii = NumberOfPoints Then
Cells(Row, 1) = BarStr
Cells(Row, 2) = EndNodeStr
Cells(Row, 3) = CaseStr
Else
Cells(Row, 1) = BarStr
Cells(Row, 2) = Str(ii) + " /" + Str(NumberOfPoints)
Cells(Row, 3) = CaseStr

End If

Set BFD = BarForceServer.Value(BarNumber, UNC, Point)
Cells(Row, 4) = BFD.FX * 0.001
Cells(Row, 5) = BFD.FZ * 0.001
Cells(Row, 6) = BFD.MY * 0.001

Set BFD = Nothing

End If


Next j
Point = Point + Step
Next ii

Next i

End If
Cells(19, 9) = ""
Cells(20, 9) = ""

End Sub

msg 26

réaction Kz

 

Raction KZ is not available thru API. You have to calculate it by yourself \ your code.

Example below - additional code in green.

Keep in mind that results strongly depend on number of points along bar and compaxity of KZ diagram.

 

.

.

.

Step = 1# / (NumberOfPoints - 1)


Dim KZReaction() As Double
ReDim KZReaction(2)
KZReaction(1) = 0#
Dim EleLen As Double
EleLen = 0#
Dim KZAComb As Boolean
Dim KZACode As Boolean
KZACode = False
KZAComb = False
Dim CCount As Integer

If CaseCol.Get(j).Type = I_CT_CODE_COMBINATION Then
CCount = CaseCol.Get(j).Components.Count
ReDim KZReaction(CCount)

For iicomp = 1 To CCount
KZReaction(iicomp) = 0#
Next iicomp
End If

For ii = 1 To NumberOfPoints

If CaseCol.Get(j).Type = I_CT_CODE_COMBINATION Then



Dim StrCC As String
StrCC = Str(CCount)

If InStr(CaseCol.Get(j).Name, "+") <> 4 And InStr(CaseCol.Get(j).Name, "-") <> 4 And InStr(CaseCol.Get(j).Name, "+") <> 8 And InStr(CaseCol.Get(j).Name, "-") <> 8 Then


For Icomp = 1 To CCount

CompStr = "/" + Right(Str(Icomp), Len(Str(Icomp)) - 1)

Row = Row + 1

If ii = 1 Then
Cells(Row, 1) = barstr + OriNodeStr + CaseStr + CompStr
ElseIf ii = NumberOfPoints Then
Cells(Row, 1) = barstr + EndNodeStr + CaseStr + CompStr
Else
Cells(Row, 1) = barstr + Str(ii) + "/" + Right(Str(NumberOfPoints), Len(Str(NumberOfPoints)) - 1) + " / " + CaseStr + CompStr
End If

Set BFD = BarForceServer.ValueEx(BarNumber, UNC, Icomp, Point)
Cells(Row, 2) = BFD.FX
Cells(Row, 3) = BFD.FZ
Cells(Row, 4) = BFD.MY
' Cells(Row, 5) = BFD.KZ

KZACode = BFD.KZAvailable
If KZACode Then
EleLen = RBar.Length / (NumberOfPoints - 1)

If ii = 1 Or ii = NumberOfPoints Then EleLen = EleLen / 2
' Cells(Row, 6) = BFD.KZ * EleLen
KZReaction(Icomp) = KZReaction(Icomp) + BFD.KZ * EleLen
End If
Set BFD = Nothing
Next Icomp
End If
Else
Row = Row + 1
If ii = 1 Then
Cells(Row, 1) = barstr + OriNodeStr + CaseStr
ElseIf ii = NumberOfPoints Then
Cells(Row, 1) = barstr + EndNodeStr + CaseStr
Else
Cells(Row, 1) = barstr + Str(ii) + "/" + Right(Str(NumberOfPoints), Len(Str(NumberOfPoints)) - 1) + " / " + CaseStr
End If

Set BFD = BarForceServer.Value(BarNumber, UNC, Point)
Cells(Row, 2) = BFD.FX
Cells(Row, 3) = BFD.FZ
Cells(Row, 4) = BFD.MY
' Cells(Row, 5) = BFD.KZ
KZAComb = BFD.KZAvailable
If KZAComb Then
EleLen = RBar.Length / (NumberOfPoints - 1)

If ii = 1 Or ii = NumberOfPoints Then EleLen = EleLen / 2
' Cells(Row, 6) = BFD.KZ * EleLen
KZReaction(1) = KZReaction(1) + BFD.KZ * EleLen
End If
Set BFD = Nothing

End If
Point = Point + Step

Next ii
If KZAComb Then
Cells(Row, 7) = "KZ Reaction for bar " & Str(BarNumber) & " Case " & CaseStr
Cells(Row, 8) = KZReaction(1)
KZAComb = False
End If
If KZACode Then
For Icomp = 1 To CCount
Cells(Row - CCount + Icomp, 7) = "KZ Reaction for bar " & Str(BarNumber) & " Case " & CaseStr & " /" & Str(Icomp)
Cells(Row - CCount + Icomp, 8) = KZReaction(Icomp)
KZACode = False
Next Icomp
End If
Next j
Next i

End If
Cells(20, 8) = ""
Cells(20, 9) = ""
End Sub
0 Likes

msg 41

 

        Dim obj As RobotObjObject
        Dim FECollection As RobotFiniteElementCollection
        Dim FEs As String
        Dim NodesSel As String
        Dim NodeSelection As RobotSelection
        Dim NodeCollection As RobotNodeCollection
        
        Set RSelection = RobApp.Project.Structure.Selections.Create(I_OT_FINITE_ELEMENT)
        Set NodesSelection = RobApp.Project.Structure.Selections.Create(I_OT_NODE)
        RSelection.FromText ""
        NodesSelection.FromText " "
        
        For jj = 1 To PanelCol.Count
            Set obj = RobApp.Project.Structure.Objects.Get(PanelCol.Get(jj).Number)
            FEs = obj.FiniteElems
            NodeSel = obj.Nodes
            RSelection.AddText (FEs)
            NodesSelection.AddText (NodeSel)
        Next jj
        
        Set RSelection = RobApp.Project.Structure.Selections.Create(I_OT_FINITE_ELEMENT)
        
                
        If (OptionButton1.Value) Then
            Set RSelection = RobApp.Project.Structure.Selections.Get(I_OT_FINITE_ELEMENT)
            If (RSelection.Count = 0) Then
                MsgBox "FEs not selected", vbOKOnly, "ERROR"
                RobApp.Interactive = True
            Exit Sub
            End If
        End If
        
        If (OptionButton2.Value) Then
            Set NodesSelection = RobApp.Project.Structure.Selections.Get(I_OT_NODE)
            num_node = Cells(9, 2)
            If num_node <> "" Then
                NodesSelection.FromText num_node
                Set NodesSelection = RobApp.Project.Structure.Nodes.GetMany(NodesSelection)
            Else
                If (NodesSelection.Count = 0) Then
                    MsgBox "Nodes not selected", vbOKOnly, "ERROR"
                    RobApp.Interactive = True
                    Set NodesSelection = Nothing
                    Exit Sub
                End If
            End If
        End If
        
        Set FECollection = RobApp.Project.Structure.FiniteElems.GetMany(RSelection)
        Set NodeCollection = RobApp.Project.Structure.Nodes.GetMany(NodesSelection)

 

msg 49

Stephanekapetanovic_0-1734071792662.jpeg

msg 53

....
            ElseIf (RCaseCol.Get(ii).Type = I_CT_CODE_COMBINATION) Then
          
                Dim CCount As Integer
                Dim CCa As RobotCodeCombination
                Set CCa = RCaseCol.Get(ii)
                CCount = CCa.Components.Count
                Dim StrCC As String
                StrCC = Str(CCount)
                
                If InStr(RCaseCol.Get(ii).Name, "+") <> 4 And InStr(RCaseCol.Get(ii).Name, "-") <> 4 And InStr(RCaseCol.Get(ii).Name, "+") <> 8 And InStr(RCaseCol.Get(ii).Name, "-") <> 8 Then
                    FEparams.Case = CCa.Number
                    
                    For icomp = 1 To CCount
                        row = row + 1
                        FEparams.CaseCmpnt = icomp
   
                    If (OptionButton1.Value) Then Cells(row, 1) = Str(FEparams.Element) + " / " + Str(FEparams.Case) + " / " + Str(FEparams.CaseCmpnt)
                    If (OptionButton2.Value) Then Cells(row, 1) = Str(FEparams.Node) + " / " + Str(FEparams.Case) + " / " + Str(FEparams.CaseCmpnt)
                    If (OptionButton3.Value) Then Cells(row, 1) = Str(FEparams.Panel) + " / " + Str(FEparams.Node) + " / " + Str(FEparams.Case) + " / " + Str(FEparams.CaseCmpnt)
                
                    Set FEresults = RobApp.Project.Structure.Results.FiniteElems.Detailed(FEparams)
                    Cells(row, 2) = FEresults.QXX
                    Cells(row, 3) = FEresults.QYY
                    Set FEcomplex = RobApp.Project.Structure.Results.FiniteElems.Complex(FEparams)
                    Cells(row, 4) = FEcomplex.MXX_TOP
                    Cells(row, 5) = FEcomplex.MXX_BOTTOM
                    Cells(row, 6) = FEcomplex.MYY_TOP
                    Cells(row, 7) = FEcomplex.MYY_BOTTOM
                    Next icomp
                    
                End If
...

msg 67

Stephanekapetanovic_0-1734072364240.jpeg

 

 

 

0 Likes

msg 70

ElseIf (RCaseCol.Get(ii).Type = I_CT_CODE_COMBINATION) Then
          
                Dim CCount As Integer
                Dim CCa As RobotCodeCombination
                Set CCa = RCaseCol.Get(ii)
                CCount = CCa.Components.Count
                Dim StrCC As String
                StrCC = Str(CCount)
                
                If InStr(RCaseCol.Get(ii).Name, "+") <> 4 And InStr(RCaseCol.Get(ii).Name, "-") <> 4 And InStr(RCaseCol.Get(ii).Name, "+") <> 8 And InStr(RCaseCol.Get(ii).Name, "-") <> 8 Then
                    FEparams.Case = CCa.Number
                    
                    For icomp = 1 To CCount
                        row = row + 1
                        FEparams.CaseCmpnt = icomp
   
                    If (OptionButton1.Value) Then Cells(row, 1) = Str(FEparams.Element) + " / " + Str(FEparams.Case) + " / " + Str(FEparams.CaseCmpnt)
                    If (OptionButton2.Value) Then Cells(row, 1) = Str(FEparams.Node) + " / " + Str(FEparams.Case) + " / " + Str(FEparams.CaseCmpnt)
                    If (OptionButton3.Value) Then Cells(row, 1) = Str(FEparams.Panel) + " / " + Str(FEparams.Node) + " / " + Str(FEparams.Case) + " / " + Str(FEparams.CaseCmpnt)
                
                    Set FEresults = RobApp.Project.Structure.Results.FiniteElems.Detailed(FEparams)
                    Cells(row, 2) = FEresults.QXX
                    Cells(row, 3) = FEresults.QYY
                    Set FEcomplex = RobApp.Project.Structure.Results.FiniteElems.Complex(FEparams)
                    Cells(row, 4) = FEcomplex.MXX_TOP
                    Cells(row, 5) = FEcomplex.MXX_BOTTOM
                    Cells(row, 6) = FEcomplex.MYY_TOP
                    Cells(row, 7) = FEcomplex.MYY_BOTTOM
                    Next icomp
                Else
                
                    row = row + 1
                
                    If (OptionButton1.Value) Then Cells(row, 1) = Str(FEparams.Element) + " / " + Str(FEparams.Case)
                    If (OptionButton2.Value) Then Cells(row, 1) = Str(FEparams.Node) + " / " + Str(FEparams.Case)
                    If (OptionButton3.Value) Then Cells(row, 1) = Str(FEparams.Panel) + " / " + Str(FEparams.Node) + " / " + Str(FEparams.Case)
                
                    Set FEresults = RobApp.Project.Structure.Results.FiniteElems.Detailed(FEparams)
                    Cells(row, 2) = FEresults.QXX
                    Cells(row, 3) = FEresults.QYY
                    Set FEcomplex = RobApp.Project.Structure.Results.FiniteElems.Complex(FEparams)
                    Cells(row, 4) = FEcomplex.MXX_TOP
                    Cells(row, 5) = FEcomplex.MXX_BOTTOM
                    Cells(row, 6) = FEcomplex.MYY_TOP
                    Cells(row, 7) = FEcomplex.MYY_BOTTOM
                End If
            End If

msg 73

Stephanekapetanovic_0-1734072063663.png

 

0 Likes