Hello,
I'm trying to obtain, with the RFEM5 COM api, all the nodal displacements for a given load case, via a VB script inside excel.
I'm especially interested in getting displacements in all the FE MESH nodes.
The following script works properly but outputs the displacements ONLY on the "model" nodes, and not the displacements in the "internal" nodes that are generated during meshing.
My question is the following: how can I have access to the whole mesh displacement data?
Thank you,
Andy
I'm trying to obtain, with the RFEM5 COM api, all the nodal displacements for a given load case, via a VB script inside excel.
I'm especially interested in getting displacements in all the FE MESH nodes.
The following script works properly but outputs the displacements ONLY on the "model" nodes, and not the displacements in the "internal" nodes that are generated during meshing.
My question is the following: how can I have access to the whole mesh displacement data?
Code:
'------------------ Sub GetNDInFENodes() Range("A3:D3000").ClearContents Dim model As RFEM5.model Set model = GetObject(, "RFEM5.Model") model.GetApplication.LockLicense On Error GoTo e Dim results As IResults Set results = model.GetCalculation.GetResultsInFENodes(LoadCaseType, common.GetSelectedLoadType) Dim deformations() As NodalDeformations deformations = results.GetAllNodalDeformations() Dim r, pos As Long pos = 3 For r = 0 To UBound(deformations) Cells(pos, 1) = deformations(r).NodeNo Cells(pos, 2) = deformations(r).Displacements.X Cells(pos, 3) = deformations(r).Displacements.Y Cells(pos, 4) = deformations(r).Displacements.Z pos = pos + 1 Next e: If Err.Number Then MsgBox Err.Description, , Err.Source Set results = Nothing model.GetApplication.UnlockLicense Set model = Nothing End Sub '------------------
Andy
Kommentar