Helpful Questions & Answers

  • FAQ

27 April 2020

004409

Thomas Günthel

Results

RFEM

RF-COM

How can I create a section via the COM interface?

Answer

In principle, a section is an element, such as a member, and is also created in the same way. First, the interface to the objects is required. For a member, this would be IModelData, and for sections, it would be ISections. This interface can be found in IModel3:

Sub test_section()
'   get interface from the opened model and lock the licence/program
    Dim iModel As RFEM5.IModel3
    Set iModel = GetObject(, "RFEM5.Model")
    iModel.GetApplication.LockLicense
    
On Error GoTo E
    
    Dim iSecs As RFEM5.ISections
    Set iSecs = iModel.GetSections()

All sections created previously are deleted first, and then two new sections are created.
The first section should be a solid section with a visible sectional area (see Figure 01). The data are entered in a similar way as in RFEM. As a type, "SectionOnSectionalArea" is selected, the corner points of the section are set by using "EdgePoint," and a "Vector" defines the direction of the section:

   '   first delete all sections
    iSecs.PrepareModification
    iSecs.DeleteObjects ("All")
    iSecs.FinishModification
    
    '   set section on solid
    Dim sec As RFEM5.Section
    sec.EdgePointA.X = 2
    sec.EdgePointA.Y = 5
    sec.EdgePointA.Z = 0
    sec.EdgePointB.X = 2
    sec.EdgePointB.Y = 8
    sec.EdgePointB.Z = 0
    
    sec.no = 1
    sec.Name = "solid section"
    sec.Plane = GlobalPlaneInPositiveX
    sec.ShowValuesInIsolines = False
    sec.Type = SectionOnSolidSectionLine
    sec.ObjectList = "1"
    
    iSecs.PrepareModification
    iSecs.SetSection sec
    iSecs.FinishModification

As already known from other elements, the new section is finally transferred in a Prepare-/FinishModification block. As the second section, a surface section is to be created (see Figure 02). For this, it is necessary to use the "SectionViaSurfacePlane" type. In addition to the vector of the section direction, you have to select the display plane of the results for the surface section. In the following example, the xy plane is selected by setting "GlobalPlaneInPositiveX."

'   set section on surface
    sec.EdgePointA.X = 2
    sec.EdgePointA.Y = 0
    sec.EdgePointA.Z = 0
    sec.EdgePointB.X = 2
    sec.EdgePointB.Y = 3
    sec.EdgePointB.Z = 0
    
    sec.no = 2
    sec.Name = "surface section"
    sec.Plane = GlobalPlaneInPositiveX
    
    sec.ShowValuesInIsolines = True
    sec.Type = SectionViaSurfacePlane
    sec.ObjectList = "1"
    
    sec.Vector.X = 0
    sec.Vector.Y = 0
    sec.Vector.Z = 1
    
    iSecs.PrepareModification
    iSecs.SetSection sec
    iSecs.FinishModification

It is also possible to get the results of a section by using the separate method "GetResultsInSection" of the "IResults2" interface. In the following, the shear forces on the surface section are obtained. The distribution of the internal forces is set to "Continuous within Surfaces" by means of "ContinuousDistributionWithinObjects":

 '   get results
    Dim iCalc As ICalculation2
    Set iCalc = iModel.GetCalculation
    
    Dim iRes As IResults2
    Set iRes = iCalc.GetResultsInFeNodes(LoadCaseType, 1)
    
    Dim secRes() As RFEM5.SectionResult
    secRes = iRes.GetResultsInSection(2, AtNo,
      ShearForceVy,ContinuousDistributionWithinObjects, False)

Under Downloads, you can find the Excel macro and the test file to comprehend the program.

Keywords

Section COM ISection

Downloads

Write Comment...

Write Comment...

  • Views 181x
  • Updated 26 February 2021

Contact us

Did you find your question?
If not, contact us via our free e-mail, chat, or forum support, or send us your question via the online form.

+49 9673 9203 0

info@dlubal.com

CSA S16: 19 Steel design in RFEM

CSA S16:19 Steel Design in RFEM

Webinar 10 March 2021 2:00 PM - 3:00 PM EST

Online Training | English

Eurocode 5 | Timber structures according to EN 1995-1-1

Online Training 17 March 2021 8:30 AM - 12:30 PM CET

Online Training | English

Eurocode 3 | Steel structures according to DIN EN 1993-1-1

Online Training 18 March 2021 8:30 AM - 12:30 PM CET

Online Training | English

RFEM | Dynamics | USA

Online Training 23 March 2021 1:00 PM - 4:00 PM EST

Plate and Shell Buckling Utilizing Dlubal Software

Plate and Shell Buckling Utilizing Dlubal Software

Webinar 30 March 2021 2:00 PM - 2:45 PM

RFEM for Students | USA

Online Training 21 April 2021 1:00 PM - 4:00 PM EST

RFEM | Timber | USA

Online Training 5 May 2021 1:00 PM - 4:00 PM EST

Online Training | English

Eurocode 3 | Steel structures according to DIN EN 1993-1-1

Online Training 6 May 2021 8:30 AM - 12:30 PM

Online Training | English

Eurocode 2 | Concrete structures according to DIN EN 1992-1-1

Online Training 11 May 2021 8:30 AM - 12:30 PM

Online Training | English

Eurocode 5 | Timber structures according to DIN EN 1995-1-1

Online Training 20 May 2021 8:30 AM - 12:30 PM

Online Training | English

RFEM | Structural dynamics and earthquake design according to EC 8

Online Training 2 June 2021 8:30 AM - 12:30 PM

Online-Schulungen | English

RFEM | Basics | USA

Online Training 17 June 2021 9:00 AM - 1:00 PM EST

The Most Common User Errors With RFEM and RSTAB

The Most Common User Errors With RFEM and RSTAB

Webinar 4 February 2021 2:00 PM - 3:00 PM CET

Member design according to ADM 2020 in RFEM

ADM 2020 Member Design in RFEM

Webinar 19 January 2021 2:00 PM - 3:00 PM EST

Dlubal Info Day

Dlubal Info Day Online | 15 December 2020

Webinar 15 December 2020 9:00 AM - 4:00 PM CET

Stability Design in Steel Construction with RFEM and RSTAB

Stability Design in Steel Construction with RFEM and RSTAB

Webinar 1 December 2020 2:00 PM - 2:45 PM CET

FEM - Troubleshooting and Optimization in RFEM

FEA Troubleshooting and Optimization in RFEM

Webinar 11 November 2020 2:00 PM - 3:00 PM EST

Soil-Structure Interaction in RFEM

Soil-Structure Interaction in RFEM

Webinar 27 October 2020 2:00 PM - 2:45 PM CET

NBC 2015 Modal Response Spectrum Analysis in RFEM

Webinar 30 September 2020 2:00 PM - 3:00 PM EST

Documenting Results in the RFEM Printout Report

Documenting Results in the RFEM Printout Report

Webinar 25 August 2020 2:00 PM - 2:45 PM

ACI 318-19 Concrete Design in RFEM

Webinar 20 August 2020 2:00 PM - 3:00 PM EST

How to Be More Productive Using RFEM

How to Be More Productive Using RFEM

Webinar 7 July 2020 3:00 PM - 4:00 PM

Introduction to Solid Modeling \n in RFEM

Introduction to Solid Modeling in RFEM

Webinar 30 June 2020 2:00 PM - 3:00 PM EST

Modeling with Solids in RFEM

Modeling with Solids in RFEM

Webinar 9 June 2020 3:00 PM - 3:45 PM

RFEM Main Program
RFEM 5.xx

Main Program

Structural engineering software for finite element analysis (FEA) of planar and spatial structural systems consisting of plates, walls, shells, members (beams), solids and contact elements

Price of First License
3,540.00 USD
RFEM Other
RF-COM 5.xx

Add-on Module

Programmable interface (API) based on the COM technology

Price of First License
580.00 USD