Multiframe Automation
Multiframe Automation
Windows Version 10
Automation Manual
DISCLAIMER OF WARRANTY
Neither Formation Design Systems, nor the author of this program and documentation
are liable or responsible to the purchaser or user for loss or damage caused, or alleged to
be caused, directly or indirectly by the software and its attendant documentation,
including (but not limited to) interruption on service, loss of business, or anticipatory
profits. No Formation Design Systems distributor, or agent, or employee is authorized to
make any modification, extension, or addition to this warranty.
iii
Table of Contents
License & Copyright .........................................................................................................iii
Table of Contents ............................................................................................................... v
About this Manual .............................................................................................................. 7
Chapter 1 Introduction........................................................................................................ 9
Automation ....................................................................................................9
VBA ...............................................................................................................9
Object Models..............................................................................................10
Uses of Automation .....................................................................................10
What can’t I automate? ................................................................................10
Terminology.................................................................................................11
Speed............................................................................................................11
Code Samples ..............................................................................................11
Early and Late Binding ................................................................................12
Object Browser ............................................................................................13
Further Reading ...........................................................................................13
Chapter 2 The Multiframe Object Model ......................................................................... 15
Collections, Objects and Lists......................................................................15
Application Object .......................................................................................17
Preferences Object .......................................................................................17
Sections Library Object ...............................................................................17
Frame Object................................................................................................18
Nodes and Elements.....................................................................................19
Members ......................................................................................................19
Springs, Restraints and NodeMasses ...........................................................19
NodeLinkGroups .........................................................................................20
LoadCases and the Loading objects.............................................................20
GroupSets and Groups .................................................................................20
ProjectInfo ...................................................................................................21
The Analysis Objects ...................................................................................21
Results Hierarchy.........................................................................................21
Indices, Numbers and ID’s ..........................................................................22
Common Properties and Methods................................................................22
Arrays ..........................................................................................................24
Variant Parameters in Methods....................................................................24
Chapter 3 Getting Started ................................................................................................. 27
A Simple Macro...........................................................................................27
A Basic Multiframe Script ...........................................................................27
Creating a Portal Frame ...............................................................................28
Applying Loads............................................................................................31
Running an Analysis....................................................................................32
Units.............................................................................................................33
The Final Script ...........................................................................................33
Chapter 4 Modelling the Frame........................................................................................ 35
Frame Object................................................................................................35
Nodes ...........................................................................................................38
Elements.......................................................................................................43
Restraints .....................................................................................................53
Springs .........................................................................................................55
Node Linking ...............................................................................................57
Node Masses ................................................................................................60
v
GroupSets.....................................................................................................63
Groups..........................................................................................................64
Members ......................................................................................................67
Project Details..............................................................................................71
Improving performance with lists................................................................72
Chapter 5 The Load Objects............................................................................................. 75
Load Cases...................................................................................................75
Node Loads ..................................................................................................78
Prescribed Displacements ............................................................................80
Element loads...............................................................................................81
Thermal Loads .............................................................................................85
Deleting Loads.............................................................................................87
Expression Parsing and Variants .................................................................88
Chapter 6 Automating Analysis ....................................................................................... 89
Linear Static Analysis..................................................................................90
Non-linear Static Analysis ...........................................................................90
Modal Analysis ............................................................................................92
Time History Analysis .................................................................................93
Chapter 7 Results Objects ................................................................................................ 95
The Results Object.......................................................................................95
Result Cases.................................................................................................96
Linear and Non-linear Results .....................................................................97
Modal Results ..............................................................................................98
Nodal Results...............................................................................................99
Element Results .........................................................................................101
Member Results .........................................................................................107
Chapter 8 Sections Library............................................................................................. 109
SectionsLibrary Object ..............................................................................109
SectionGroup Object..................................................................................111
Sections Object ..........................................................................................113
Chapter 9 Preferences and Units .................................................................................... 119
Sign Conventions.......................................................................................119
Units...........................................................................................................119
Chapter 10 Collections and Lists.................................................................................... 121
Collections .................................................................................................121
Lists............................................................................................................122
The Find Method .......................................................................................126
Chapter 11 User Interface............................................................................................... 127
Selection Object.........................................................................................127
Chapter 12 Examples...................................................................................................... 131
Reproducing Multiframes Data Window in Excel.....................................131
Reproducing Multiframes Result Window in Excel ..................................137
Customised Reporting using Word............................................................137
Appendix A Object Model Summary............................................................................. 141
Objects .......................................................................................................141
Enumerated Types .....................................................................................142
Index............................................................................................................................... 147
vi
About this manual
Chapter 2 The Multiframe Object Model; Presents an overview of the Multiframe Object
model by describing each of the objects used within the model.
Chapter 3 Getting Started; Gets you started writing a simple script to automate
Multiframe. It is a simple series of exercises designed to introduce you to many of the
objects within the Multiframe object model.
Chapter 4 Modelling the Frame; Presents a detailed description of the objects used in
modelling the structure. This includes objects describing joints, elements, restraints,
joint linking and design members.
Chapter 5 The Load Objects; In this chapter the objects used for loading a structure are
discussed. Objects used for describing load cases and each of the individual loads are all
described in detail.
Chapter 6 Automating Analysis; This chapter describes the objects used to control and
execute and analysis.
Chapter 7 Results Objects; The results of analyses are available via the Multiframe
Object model and are accessed via a hierarchy of objects that are described in this
chapter.
Chapter 8 Sections Library; Describes the objects that represent sections, groups and the
sections library.
Chapter 9 Preferences and Units; Provides a description of the objects that control the
settings and units used within Multiframe.
Chapter 10 Collections and Lists; This chapter outlines the use of collections and lists to
manage groups of objects.
Chapter 11 User Interface; This chapter describes which items in the Multiframe user
interface can be controlled using Automation.
Page 7
Chapter 1 Introduction
Chapter 1 Introduction
This chapter provides an introduction to automation, VBA and object models and their
use in writing macros for Multiframe. It discusses the applications that can be used to
access and control Multiframe and presents examples on how this can be done.
Automation
Automation is a term used to describe the ability of one application to control or access
data from another. Automation is a common feature in many Microsoft applications such
as Word and Excel. In fact, the macros in each of these applications are written using
automation. The automation interface in these applications gives a user access to a range
of objects that can be used to control the application and its data. For example, Microsoft
Word contains paragraph, word and font objects. In a similar way, Multiframe’s
automation interface contains node, element and load objects amongst others.
Multiframe provides support for automation via an interface that allows the user to create
a frame, perform an analysis and examine the results. While the Multiframe application
does not incorporate a facility for directly writing or recording macros, the automation
interface will allow users to develop macros for Multiframe in other applications.
Multiframe’s automation interface enables it to interact with many other applications that
support automation. This is very easily achieved in applications that provide a suitable
VBA macro-programming environment such as
• Microsoft Excel
• Microsoft Word
• Microsoft Access
• AutoCAD 2000
• MathCAD
Automation can also be used via many modern programming languages such as Visual
Basic, Visual C++, Java and even Compaq Visual Fortran. It is even supported by the
Windows Scripting Host, which can be used to automate applications directly from the
Windows environment.
VBA
Visual Basic for Applications, or simply VBA, is Microsoft’s application scripting
language. It is the language used to write macros within the entire Microsoft Office suite
and in other Microsoft products. It is also used within applications written by other
vendors such as AutoCAD and MathCAD. If you have experience in writing macros
within any of these products then you should be able to quickly adapt to writing macros
for Multiframe.
Page 9
Chapter 1 Introduction
VBA is the most readily available platform in which to write Multiframe macros as most
engineers have access to Microsoft Excel or Microsoft Word. It is also a relatively easy
environment in which to develop scripts, macros or small programs that exploit
automation. As such, this manual will concentrate of the use of VBA for the
development of macros for Multiframe. All examples presented in the manual will be
coded using VBA.
Object Models
The key to the use of VBA within all these different applications is that VBA is simply a
language for manipulating objects. Each application that uses VBA for scripting has its
own object model that is a unique set of objects that can be manipulated by the language.
If you are familiar with VBA then learning to write macros for another application only
involves learning that application’s object model. By mastering the use of VBA for
writing Multiframe macros you will also be able to quickly adapt to writing macros in
many other products.
Uses of Automation
Automation is a powerful tool that can be used to write anything from a simple macro to
a full windows application. In fact this is the technology that allows Multiframe to
directly generate reports in Microsoft word. Some examples of how this technology
could be employed are:
• A macro to manipulate the geometry of a selection in the Frame Window, for
example a mirror function.
• Generating customised reports in Microsoft Word
• Generating HTML reports using Microsoft Word
• Exporting data to a Microsoft Access database that could be used to manage
fabrication or perform a costing
• Writing a VB program to import or export a structure to other file formats or
programs
• Writing a script to find members with particular properties
• Writing Excel macros to automatically access design data from Multiframe
• Batch processing of analyses overnight using Windows Scripting
Each of these examples could be designed as a simple macro or with a sophisticated user
interface. Once familiar with VBA, it is an easy task to add dialogs and menus to your
automation scripts.
Page 10
Chapter 1 Introduction
Terminology
The terminology used in the automation interface is slightly different to that used in the
Multiframe user program. Each nodal point in the structure is referred to as a Joint in the
program but as a Node in the automation interface. In addition, a Member in the
program is called an Element in the automation interface while a Member in the
automation interface is a Design Member in the program.
Speed
An important issue in automation programming is speed; automated scripts or macros
can be relatively slow when they require making calls between applications. There are a
number of techniques for helping to improve their performance, the most important of
which is to minimize the number of calls between applications. The Multiframe
automation interface has been designed to provide the advanced user with a number of
techniques for minimizing the number of calls across the interface. This includes using
collections and lists to add or modify a group of objects at once and the exchange of data
using arrays contained within VARIANT data types. Examples of these are given in
Chapter 10 Collections and Lists and in Chapter 12 Examples.
Code Samples
This manual features many example scripts to demonstrate how the objects, properties
and methods of the Multiframe Automation interfaced are used. Unless otherwise noted,
these scripts are written in VBA and were developed using either Microsoft Excel or
Microsoft Word. Most of the scripts in the manual can be executed by inserting the code
between the dashed lines in the following macro.
Sub Test()
'definition of app and frame objects
Dim mfApp As New Multiframe.Application
Dim myFrame As Multiframe.Frame
Set myFrame = mfApp.Frame
'----------------------------
End Sub
Note that many of the scripts will require a suitable structure to be present within the
Multiframe application as they refer directly to particular nodes, elements or load cases.
Page 11
Chapter 1 Introduction
All the example code presented in this manual was written using the VBA editor
provided within Microsoft Office 2000. This code uses some features not available in
the version of VBA provided with earlier versions of Microsoft Office. One significant
difference is that the older version of VBA does not support the use of enumerated data
types which have been used throughout the Multiframe Object model. For this reason
we recommend the use of Microsoft Office 2000 products when writing VBA scripts.
However, scripts can still be written using Office 97 in which case enumerated values
must be replaced by their integer value. All the enumerated types, and their values, used
by the Multiframe Automation Model are listed in Appendix A of this document.
Scroll down the list of available references until you find the Multiframe Object Library.
Select this item by clicking in the box to it’s left then click OK.
Page 12
Chapter 1 Introduction
Object Browser
Another advantage of using Early Binding is that you can use the Object Browser (View |
Object Browser), shown below, to examine the names, properties and methods of the
objects in the Multiframe Object library.
Further Reading
This aim of this manual is to describe the Multiframe automation interface and its use.
The manual does not aim to teach the reader how to program in VBA or any other
language. It is assumed that the reader is familiar with Visual Basic or VBA
programming or that you have access to materials on this topic. There are many books
available on VBA, particularly in relation to the Microsoft Office suite of products.
Some references and other resources that may be useful in helping you to learn VBA and
automation are:
• “Microsoft Excel 2000 Power Programming with VBA” by John Walkenbach, IDG
Books Worldwide, 1999
• A range of reference books on VBA programming with Word 2000, Excel 200 and
AutoCAD 2000 is published by Wrox Press, www.wrox.com
• http://msdn.microsoft.com/office/default.asp
• www.mvps.org
• News groups
microsoft.public.word.vba.beginners
microsoft.public.word.vba.general
microsoft.public.office.developer.vba
Page 13
Chapter 2 The Multiframe Object Model
Each Object contains Properties and Methods. The Properties are a number of variables
which store properties of the object such as name, length, weight etc. The actual type and
name of the properties are specific to each type of object. Methods are functions that you
can use to manipulate the object. These might include methods to Add, Delete or modify
values of the object.
Page 15
Chapter 2 The Multiframe Object Model
Application
Frame
Nodes (Node)
Elements (Element)
Springs (Spring)
Restraints (Restraint)
NodeMasses (NodeMass)
NodeLinkGroups (NodeLinkGroup)
Loadcases (Loadcase)
NodeLoads (NodeLoad)
NodePreDisps (NodePreDisp)
ElementLoads (ElementLoad)
ThermalLoads (thermalLoad)
Members (Member)
Results
LinearResults
ModalResults MemberResults
ElementResults
ProjectInfo
NodeResults
Analysis
LinearSettings
NonlinearSettings
ModalSettings
SectionsLibrary
SectionGroups (SectionGroup)
Sections (Section)
Materials (Material)
Preferences
Page 16
Chapter 2 The Multiframe Object Model
Application Object
The root of the Multiframe object model is the Application object. All other objects
within the object model can be accessed either directly or indirectly via this object.
The application object provides direct access to three Multiframe objects as shown
below.
Application
Frame
SectionsLibrary
Preferences
The Application object contains a number of shortcuts to objects contained within the
frame. Both the load cases and results object for the current frame can be obtained
directly from the application.
Preferences Object
The preferences object provides access to settings within the Multiframe application that
control how data is presented. This includes the sign conventions used to display forces
and numerous methods for manipulating and accessing the units of measure. An
important method of the Preferences object is the GetUnit function that returns a string
containing the units name (e.g. mm, kN, ft) of a specified unit type. This is very useful
when presenting data or requesting input from a user as the units of measure can easily
be displayed. Note that all methods and properties in Multiframe automation use the
current units.
SectionsLibrary
SectionGroups (SectionGroup)
Sections (Section)
Materials (Material)
Page 17
Chapter 2 The Multiframe Object Model
This sections library object is accessed directly from the Application object using the
SectionsLibrary property. The SectionsLibrary object contains a collection of
SectionGroup objects. Each SectionGroup object in the collection corresponds directly
to a group of sections in the sections library. It contains the properties associated with a
group of sections as well as a collection of Section objects, each of which represents a
section stored within the group. A useful property of the SectionGroup object is the
SectionNames property. It returns a list of names of all the sections contained within
the group. It can be used to construct a user form or dialog containing a list of sections
from which the user may choose. This is much faster than individually accessing the
name of each section within the group
The SectionsLibrary object also contains a collection of Material objects that provides a
means for adding, deleting or editing materials in the library.
Frame Object
The Frame object represents a structural model within Multiframe. It encapsulates all of
the objects representing components of the model such as nodes, elements and restraints,
load cases and loads applied to the frame, and objects containing the results of any
analyses performed on the frame.
Frame
ProjectInfo
Nodes (Node)
Elements (Element)
Members (Member)
Restraints (Restraint)
Springs (Spring)
NodeMasses (NodeMass)
NodeLinkGroups (NodeLinkGroup)
LoadCases (LoadCase)
GroupSets (GroupSet)
Analysis
Results
Page 18
Chapter 2 The Multiframe Object Model
This object can be accessed using the Frame property of the Application object, for
example:
Dim objFrame as Multiframe.Frame
…
Set objFrame = mfApp.Frame
The Frame object also contains the methods for Opening, Closing and Saving the frame
to disk.
The Element object provides access to data describing an individual element in a frame
such as its label, section, orientation, rigid end offsets and the nodes used to define its
ends. Other read only properties provide other information about the element such as its
length, slope, and the coordinates of its ends. The Element object also provides
functions that return lists of objects associated with an element such as all loads applied
to the element.
Methods are also provided with both the Node and Element objects to transform values
from their local coordinate system to the global coordinate system and vice versa.
Members
The Member object represents a single entity for the purpose of design. This may be a
single element or a group of elements linked together to form a single design member.
This object provides methods and properties for grouping or removing elements from a
design member, setting the section and orientation of the member, as well as properties
for describing the position, slope and length of the member.
Each of these objects includes a Label property that may be used to identify the item or
contain a string of user-defined information. This property is only available via the
automation interface and cannot be edited or viewed via the user interface of the current
version of Multiframe.
Page 19
Chapter 2 The Multiframe Object Model
NodeLinkGroups
The Master-Slave facility in Multiframe is described in the Multiframe automation
interface using node link groups. Each Master-Slave grouping is encapsulated within the
NodeLinkGroup object which provides a mechanism by which to control the name of
the group, nodes contained within the group, the master node and which degrees of
freedom are linked by the group.
LoadCases (LoadCase)
NodeLoads (NodeLoad)
NodePreDisps (NodePreDisp)
ElementLoads (ElementLoad)
ThermalLoads (ThermalLoad)
The NodeLoad and NodePreDisp objects described the force and prescribed
displacement loadings that may be applied to a node within the frame. These objects
provide details of which node the load is applied to, its magnitude, direction and well as
which coordinate system in which the load is applied.
Page 20
Chapter 2 The Multiframe Object Model
GroupSets (GroupSet)
Groups (Group)
The Group object represents a single group contained within a group set. This object has
properties to access the name and colour associated with the group as well as the lists of
the elements and nodes that define the group.
ProjectInfo
The ProjectInfo object contains properties for accessing details of the project and
designer such as the project title, project description, job ID, designers name, a version
number and the date the frame was last modified. This is the same data set by the
Properties dialog in Multiframe’s File menu.
LinearSettings
NonlinearSettings
M odalSettings
The settings associated with each type of analysis that Multiframe can perform are
contained in separate objects. The LinearSettings object contains the setting required
by the linear analysis. However, this object has only been provided for consistency at
there are no setting required by the linear analysis at this stage. All the settings
associated with a nonlinear analysis are stored within the NonlinearSettings object,
while the parameters required to perform a modal or time history analysis are specified
using the ModalSettings and TimeHistorySettings objects. Note that while a time
history analysis can be performed via the automation interface, the time history loading
and results of time history analyses are not yet available.
Results Hierarchy
The results of analyses are stored in a hierarchy with the Results object at the top. As
shown below, this hierarchy divides the results from each type of analysis into separate
objects. The results from the linear analysis are contained within the LinearResults
object that in turn contains a collection of ResultCase objects, each of which corresponds
to the results for a particular load case. Each ResultCase object contains a collection of
NodeResult, ElementResult and MemberResult objects that provide an interface to
the results for each node, element or member in the frame. Similarly, the results of
nonlinear analyses are interfaced via the NonlinearResults object which also contains a
collection of ResultCases which correspond to each load case applied to the frame. Note
that each ResultCase exists irrespective of whether the case has been analysed or not. If
a case has been analysed then the Solved property of the ResultCase object returns a
value of true.
Page 21
Chapter 2 The Multiframe Object Model
Results
LinearResults
ResultCases (ResultCase)
NonlinearResults
NodeResults (NodeResult)
ModalResults
ElementResults(ElementResult)
MemberResults(MemberResult)
The results of a modal analysis are accessible via the ModalResults object. It contains a
collection of ResultCase objects representing each mode shape in the solution. The
ModalResults object also provides access to period and frequency of each mode shape.
No interface is currently available for the results from time history analyses.
The results for each node, element and member may be obtained directly by navigating
the hierarchy described above. An alternative technique is to use the GetResults
method of the respective Node, Element and Member objects.
The Number property of an object currently returns the number of the object as used
within Multiframes user interface. As this is the same as the items index, the Number
and Index property return the same value. Future versions of Multiframe may allow the
user to define the number of an item in which case the number need not be unique or part
of a continuous numbering scheme. For this reason it is suggest that the Number
properties is used when generating output such as reports.
All of the objects that are used to model a structure, including the loading, share a
number of common properties and methods. These are summarized in the following
tables.
Page 22
Chapter 2 The Multiframe Object Model
The Index, Label and Number properties are specific only to objects that are contained
within collections. Objects that do not form a collection do not have these properties.
The Label object is sometimes replaced by a Name property in which case the Label
property is a hidden property that provides an alternative means of accessing the Name
property.
The Collections objects in the Multiframe Object Model also share a common property
and method as listed below.
These collections all have a method for adding a new object to the collection. However,
the naming of this method and the parameters required by the method are not standard
and vary depending upon the collection.
The List objects also have a number of common properties and methods that are
summarised below.
Page 23
Chapter 2 The Multiframe Object Model
Arrays
All arrays used within the Multiframe automation interface are passed across the
interface as variants. This provides a lot of flexibility when passing an array to a method
or property as the array may be declared as either an array or a variant. However, when
an array of values is returned from a property or method of an object it is returned as a
variant. This means that the variable receiving the results must be declared as a variant.
Page 24
Chapter 2 The Multiframe Object Model
’Get all node loads on node 3 applied in the third load case
Set myLoads = myFrame.Nodes(3).Loads(myFrame.LoadCases(3))
Page 25
Chapter 3 Getting Started
A Simple Macro
It is not the aim of this manual to teach you how to write VBA scripts or macros. This
can be learnt from many texts available on VBA, or on many of the core Microsoft
Office products. Some assistance is also available from the online help provided with
applications supporting a VBA scripting environment. However, to help you on your
way we give a brief description of how to write a simple macro. To begin writing a
macro you must first open the VBA development environment. In the Microsoft Office
products this is generally performed via the Tools | Macro | Visual Basic Editor
command. Add the following text to the content of a file open within this window.
Sub Hello()
End Sub
To run this macro, locate the cursor within the code and select the command Run | Run
Sub/Userform from the main menu. You should see a simple dialog saying “Hello
World”.
Page 27
Chapter 3 Getting Started
Search the list of items displayed in the resulting dialog and find the Multiframe 1.1
Object Library entry. To enable Multiframe simply click in the check box to its left and
then press OK to exit the dialog. If the reference is set up correctly you should get the
benefits of automatic assistance in the editor as you write your macros or scripts.
Amongst other things, this will automatically list the properties and methods of objects
as you write VBA code.
The VBA subroutine listed below is a simple script that uses Multiframe automation.
Type this script into the VBA programming environment.
Sub MyScript()
Dim mfApp As New Multiframe.Application
Dim myFrame As Multiframe.Frame
End Sub
Before running this script, make sure Multiframe is running and a frame has been loaded
from disk. Now run this script from the VBA environment, it will display a dialog
containing the name of the file open in Multiframe.
H2 = 5.5
H1= 5.0
W = 12.0
Each of these sections begins by introducing a small part of the Multiframe object model.
It then uses this in the development of the script for generating the portal frame. The
entire script for generating the portal frame is listed at the end of this chapter.
Page 28
Chapter 3 Getting Started
End Sub
After the declaration of variables, the script creates the five nodes required to define the
portal frame. Each node is created via a single call to the AddNode method which
returns a reference to the object that represents the new node. This reference is assigned
to the myNode variable that is declared at the start of the script as a Node object. After
the nodes have been created, each of the elements representing the members of the portal
frame are created by calling the AddElement method, which, like the AddNode
method, returns a reference to the object representing the new element. This code
assumes that the new nodes are the only nodes in the frame as it requires the nodes be
numbered from 1 to 5.
It is not always necessary to create the nodes and then add elements as elements can be
created directly by specifying the coordinates at each end of the element. Hence, the
piece of code above could be refined to
Sub CreatePortal()
Dim mfApp As New Multiframe.Application
Dim myFrame As Multiframe.Frame
Dim myEl as Multiframe.Element
‘Create elements
Set myEl=myFrame.Elements.AddElement(0.0,0.0,0.0,0.0,5.0,0.)
Set myEl=myFrame.Elements.AddElement(0.0,5.0,0.0,6.0,5.5,0.)
Set myEl=myFrame.Elements.AddElement(6.0,5.5,0.,12.0,5.0,0.)
Set myEl=myFrame.Elements.AddElement(12.0,5.0,0.,12.0,0.,0.)
End Sub
which is far more efficient as it reduces the number of subroutine calls made to
Multiframe. When creating elements in this way, Multiframe determines if a node
already exists at the specified points and connects the element to the existing node.
Otherwise a new node is created to define the end of the element.
Page 29
Chapter 3 Getting Started
Properties of Elements
Each element within a structure is represented by an Element object. This object can be
used to modify the attributes of an element such as its label, end releases or section size.
All the Element objects representing the elements of a frame are contained within an
Elements collection in the Frame. The Elements collection is arranged in numerical
order such that element number 4 is the 4th element in the collection. A reference to the
object representing this element would be obtained from the collection as follows
Dim myEl as Multiframe.Element
Set myEl = mfApp.Frame.Elements(4)
All attributes of this element that can be set in Multiframe can also be accessed and
modified using the Element object. For example, the orientation and label of the
element could be set using the following two lines of code.
myEl.Orientation = 45 ‘Set orientation to 45 degrees
myEl.Label = ”Beam B2” ‘Set label
The section type associated with an element is set using the SetSection method of the
Element object. This method can take a number of different parameters that are used to
specify a section from the current sections library. The first and simplest method is to
specify the section by the number of the group and the number of the section within the
group. The section can also be specified by name, in which case the entire sections
library is searched in order to match the name of the section. Examples of each of these
methods are
Call myEl.SetSection(1,2)
Call myEl.SetSection(“310UB40”) ‘Australia
Call myEl.SetSection(“W40x480”) ‘United States
Call myEl.SetSection(“150x150x7x10”) ‘Japan
For the portal frame created above, the following piece of code is used to set the section
size of each element.
In this code fragment, the section size is set by specifying the index of the group and
section. This allows the script to work with any sections library.
Applying Restraints
In Multiframe, restraints are not implemented as properties of a node. Instead, they are
considered as a separate entity that is associated with a particular node. In this way,
several restraints can be applied to a single node. This is reflected in the Multiframe
automation model in which each restraint applied to a node is represented by a separate
Restraint object. The object contains the attributes of a restraint such as the node to
which is applied and the degrees of freedom it restrains. All the restraints within a
structure are stored in the Restraints collection in the Frame object.
Page 30
Chapter 3 Getting Started
A new restraint can be applied to a structure by adding a new object to the Restraints
collection using the AddRestraint method. This method takes two parameters; the first
parameter specifies the node at which the restraint is to be applied. The second
parameter specifies the degrees of freedom to be restrained. This parameter can take
many forms but the simplest means of identifying the restrained freedoms is using
constants representing common type of restrains. For the portal frame we are developing
in the example, we need to apply rigid restraints at the 1st and 5th node in the frame.
These restraints are added to the model using the following code.
Dim myRestraint as Multiframe.Restraint
With mfApp.Frame.restraints
Set myRestraint = .AddRestraint(1, mfRestraintFixed)
Set myRestraint = .AddRestraint(5, mfRestraintFixed)
End With
If you were using Office 97, the above script would need to be programmed
using a value of 2 instead of enumerated constant mfRestraintFixed. You
can also import the list of types from the Types module contained in the
Office 97 examples provided with Multiframe.
Applying Loads
A load case applied to a frame is represented within the Multiframe object model using
the Loadcase object. This object contains the attributes of a load case such as its name,
type, etc. It also contains several collections containing the loads applied in the load
case. All the load cases applied to a structure are stored in a Loadcases collection that
is contained within the Frame object. A new load case is added to a frame using the
AddCase method of this collection. This method takes two parameters that specify the
type and name of the load case.
The following code fragment is used in the portal frame script to define three load cases,
a self weight case, a live load case and a factored case that combines the first two cases.
Page 31
Chapter 3 Getting Started
A similar syntax is used to add other loads such as thermal, joint loads or prescribed
displacements.
The load case factors used to define a combined load case are also stored as properties of
the Loadcase object. They can be set using the Factor property of this object which,
unlike many properties, takes a single parameter that identifies the index of the load case
for which the load case factor is being set. In our portal frame example, this property is
used as follows.
This snippet of code defines the factors for the 3rd load case that is a combination of the
1st load case and 1.25 time the 2nd load case.
Running an Analysis
The frame currently open in Multiframe can be analysed using the Analysis object. This
object manages the setting for each of the different analyses, records which analyses are
to be performed, and executes the analysis. The following code fragment is used to
perform a linear analysis of the portal frame.
'Perform linear analysis
With mfApp.Frame.Analysis
.Linear = True
.Nonlinear = False
.Analyse
End With
This code accesses the Linear and Nonlinear properties of the Analysis object to set
which analyses are to be performed. The analysis is then executed within Multiframe by
calling the Analyse method.
Page 32
Chapter 3 Getting Started
Units
In this example we have so far avoided the mention of which units we are using to
construct the frame. This has been deliberate as the units used when scripting the VBA
can be any unit supported within Multiframe. In fact, when working with the automation
interface, all values are specified using the current units set that is been used within the
application. The units may be interrogated or manipulated using the Preferences
object. The Units property of the Preferences object specifies the current unit set. This
may be set to one of predefined sets of units (Australian, Japanese, American, etc.) by
setting it to an enumerated value of type mfUnitSets. For example, the Japanese unit set
may be specified by setting
mfApp.Preferences.UnitSet = mfUnitsetJapanese
The specific units used with a unit set can be manipulated via the SetUnit method of the
Preferences object. This method takes two parameters; the first is an enumerated value
identifying the type of units (length, force, angle, etc) to be set. The second parameter is
a string that specifies the name of the units to be used. For example, to change the units
for length to feet would require the code
mfApp.Preferences.SetUnits(mfUnitLength,”ft”)
Allowable values of the unit names are those listed in Multiframe’s Units dialog for each
of the units types.
For the portal frame script, metric units have been adopted. This is done by inserting the
following piece of code at the start of the script following the declaration of variables.
'Set units
With mfApp.Preferences
.UnitSet = mfUnitsetAustralian
Call .SetUnit(mfUnitLength, "m")
Call .SetUnit(mfUnitForce, "kN")
End With
This short piece of code specifies to use the Australian unit set and then ensures that the
length and force units are set to metres and kilonewtons respectively.
'Declare variables
Dim mfApp As New Multiframe.Application
Dim myLC As Multiframe.LoadCase
Dim myEl As Multiframe.Element
Dim myLoad As Multiframe.ElementLoad
Dim myRest As Multiframe.Restraint
'Set units
With mfApp.Preferences
.UnitSet = mfUnitsetAustralian
Call .SetUnit(mfUnitLength, "m")
Call .SetUnit(mfUnitForce, "kN")
Page 33
Chapter 3 Getting Started
End With
End Sub
Page 34
Chapter 4 Modelling the Frame
Frame Object
The Frame object is a very important object as it contains all the objects and collects
which describe the frame currently open within the Multiframe application. This includes
all elements used to model the geometry of the frame, the loading and the results of
analyses performed on the frame. The frame object is also responsible for managing the
storage and retrieval of the frame to file.
Frame
Nodes (Node)
Elements (Element)
Springs (Spring)
Restraints (Restraint)
NodeMasses (NodeMass)
NodeLinkGroups (NodeLinkGroup)
Loadcases (Loadcase)
Members (Member)
Results
ProjectInfo
Analysis
A summary of all the properties and methods of a Frame object are listed in the table
below.
Page 35
Chapter 4 Modelling the Frame
Page 36
Chapter 4 Modelling the Frame
Properties
The geometry and topology of a structural model is defined by its nodes and elements.
All the nodes and elements in a frame are stored as collections of Node and Element
objects. These collections are referenced via the Nodes and Elements properties of the
Frame object. Boundary conditions are applied to the model in the form of springs,
restraints and the linking of nodal degrees of freedom. These are represented within the
object model as Spring, Restraint and NodeLinkGroup objects respectively. The
boundary conditions applied to frame are stored in collections of each of these objects
which are referenced via the Springs, Restraints and NodeLinkGroups properties of
the Frame object.
A joint mass attached to the model is defined by the NodeMass object. The
NodeMasses collection stores all the node masses applied to a frame. In
Multiframe4D, this collection can be referenced from the Frame object using the
NodeMasses property. An error message will be returned when trying to access this
collection in other versions of Multiframe. The application of Node, Spring, Element,
NodeLinkGroup and NodeMass objects in the modelling of a frame are described in
detail later in this chapter.
The loading applied to the frame is defined by the collection of LoadCases objects
associated with the frame. This collection, which is available via the LoadCases
property of the Frame object, defines each of the load cases applied to the frame. The
application of loads are described in detail in Chapter 5.
The Analysis property of the Frame object returns a reference to an Analysis object
that is responsible for the analysis of the frame. It stores the settings to be used in the
analysis, controls which analyses are to be conducted and performs the actual analysis of
the frame. A detailed description of this object is presented in Chapter 6. The results of
analyses are stored within the Results object. This is stored as part of the Frame object
and can be referenced via the Results property of this object. Chapter 7 describes the
Results object which contains a hierarchy of objects for accessing the results at each
node, element or design member within the frame.
The definition of a design member within the Multiframe object model is stored within a
Member object. All the design members within a frame are stored within a collection of
Member objects. This collection if referenced via the Members property of the Frame
object. The use of design members is described later in this chapter.
The Modified property is used to determine if the frame has been changed and needs to
be saved. This property returns a value of true if the frame has been altered. It will most
commonly be used conjunction with the methods to open and save the frame.
The details of the frame such as it title, description and name of the client are stored in a
ProjectInfo object. This object may be referenced via the ProjectInfo property of the
Frame object.
The three properties FullName, Name, and Path describe the location of the file to
which the frame is saved. The Path property contains the disk path of the file; the
Name property returns just the name of the file while the FullName property returns the
name of the file including the path.
Page 37
Chapter 4 Modelling the Frame
The Selection property of the Frame object returns the selection within one of
Multiframes windows. This is a read only property that takes a single parameter that
identifies the window containing the desired selection. If no window is specified, the
selection in the window which is currently active within Multiframe is returned. The
selection is returned as a Selection object that is discussed in Chapter 10.
The ActiveLoadCase property provides a means of interacting with the Multiframe user
interface. This property references the load case that is displayed within Multiframes
windows.
Methods
A new frame is loaded into Multiframe using the Open method of the Frame object.
The following script demonstrates how to open a new frame using VBA and Microsoft
Excel. In this example the user is prompted to select the file to be opened via the File
Open dialog.
Dim Filename As String 'name of file to open
Dim Filter As String ‘filter for section library files
End If
End With
The frame may be saved to file using the Save or SaveAs methods. The Save method
saves the frame using it’s current file name and path. The SaveAs method saves the
frame as a new file. It would be implemented within a script in a similar was to the
examples shown above for opening a frame.
The frame currently opened within Multiframe can be closed and a new frame created
using with the Close or New methods. Both these methods take a single Boolean
parameter that specifies if the existing frame is to be saved.
Finally, the SetSelection method sets the selection within a specified window. This
method is discussed in detail in Chapter 10.
Nodes
A node within a structure is represented by the Node object. This object encapsulates all
the properties of a node such as its position and orientation of the local axes. All the
nodes that form a structure are contained within the Nodes collection that is stored as
part of the Frame object.
Page 38
Chapter 4 Modelling the Frame
Frame
Nodes (Node)
A summary of all the properties and methods of the Node object are listed in the table
below.
Page 39
Chapter 4 Modelling the Frame
The Application, Frame, Number, Label and Index properties in addition to the
Delete method are common to many objects and are described in Chapter 2.
Creating Nodes
A node is added to a frame using the AddNode method of the Nodes collection. This
method has three parameters that specify the x, y and z coordinates of the node in the
global coordinate system. The y and z parameters are optional values and have a default
value of 0.0. The position of the node will be set using the current units of length that
are set within the Multiframe application. For example, the following demonstrates how
to add a node to a structure.
Dim myNode as Multiframe.Node
Dim xVar,yVar as Variant
Adding nodes one by one can be tedious and very time consuming using automation. A
virtually unlimited number of nodes can be created using the AddNodes method of the
Nodes collection. This method also has three parameters corresponding the coordinates
in the global x, y and z directions, and returns a NodeList object containing each of the
nodes added to the structure. Each of the parameters to this method may be an array of
values, containing a value for each of the new nodes, or a single value that will be
applied to each of the new nodes. The parameters for the y and z parameters are optional
and have a default value of 0.0. This is very convenient when working on a 2D structure
or even a continuous beam as the redundant direction can be ignored. Some examples of
using the AddNodes method follow.
Dim myNodeList as New Multiframe.NodeList
Dim xVar,yVar as Variant
Page 40
Chapter 4 Modelling the Frame
Properties
The Node object encapsulates the data describing a joint within a structural model.
These properties described the position of the node, the orientation of the nodes local
axes and if the node is pinned or rigid. The Node object also provides several other
properties that provide information about other items that are connected or associated
with the node such as springs, restraints and joint masses.
The position of a node in global space is specified using the x, y or z properties of the
Node object. These properties, which give the location of the node in each of the global
directions, are expressed in terms of the length units currently in use within the
Multiframe application. The coordinates of the node may also be referenced using the
xyz property that returns the position of the node as a variant containing an array of three
values.
Dim myNode as Multiframe.Node
The Pinned property of the Node object defines if a node as pinned or rigid. This
Boolean valued property is equal to true when the node is a pinned node.
A list of the springs attached to a node can be obtained using the Springs property of the
Node object. This read only property returns a SpringList object which references each
spring applied to the node. The springs attached to several nodes within a structure can
be determined using the Springs property of the NodeList object which returns a
SpringList object containing all the springs connected to any node contained within the
list of nodes.
Page 41
Chapter 4 Modelling the Frame
The UserData and UserDataUnits properties enable values other than those defined
within Multiframe to be stored with each node. These properties take a single parameter
identifying separate values to be stored with the node thus allowing any number of
values to be stored with each node. Furthermore, each value is stored as a variant data
type so that strings, numbers or even arrays may be stored with each user data entry. To
provide compatability of the user data with the handling of units within Multiframe the
type of units associated with each user data entry may be set using the UserDataUnits
property. By default each user data value is assumed to be dimensionless. A simple
example demonstrating these properties if shown below
Dim myNode as Multiframe.Node
Methods
A list of loads applied to a node can be obtained using the Loads and PreDisps methods
of the Nodes object. These methods take a single parameter identifying the load cases
that are to be considered when compiling the list of loads. This parameter is optional,
and, if omitted, this method will return all the loads applied to the node as part of any
load case within the frame. The Loads and PreDisps methods return the list of loads as
NodeLoadList or NodePreDispList objects respectively. The flexibility of these
methods is demonstrated below
Page 42
Chapter 4 Modelling the Frame
The Node object also provides two methods for transforming an array of values between
global and local nodal coordinates. These methods can transform arrays containing
either 3 or 6 values. The GlobalToLocal method, as the name suggests, transforms
values from the global coordinate system to the local nodal coordinates as defined by the
nodal orientation. Conversely, the LocalToGlobal method transforms values expressed
in the local nodal coordinates back to global coordinates. A typical application of
transforming values between coordinate systems is in transforming the reactions
(expressed in global coordinates) at a node with an inclined restraint to determine the
reactions normal to the restraint.
Dim myNode As Multiframe.Node
Dim r As Variant
Elements
The Element object represents an element within a structure. This object encapsulates
all the properties of an element such as its position, section type, end releases and
orientation of the local axes. All the elements that form a structure are contained within
the Elements collection that is stored as part of the Frame object.
Frame
Elements (Element)
Page 43
Chapter 4 Modelling the Frame
A summary of all the properties and methods of the Element object are listed in the table
below.
Page 44
Chapter 4 Modelling the Frame
The Application, Frame, Number, Label and Index properties as well as the Delete
method are common to many objects and are described in Chapter 2.
Page 45
Chapter 4 Modelling the Frame
A note on Properties
The properties of an object are most commonly used without any
parameters. However, properties may be defined to accept a parameter in
much the same way that a method accepts parameters. Unlike methods,
these properties can be directly set equal to a value. These types of
properties have been used in the Multiframe automation interface to provide
a simple means of accessing some properties. A common use is for the
properties of an element that pertain to a particular end of the element.
These are accessed via a single property of the Element object that accepts
a single parameter identifying an end of the element. One such example is
the rigid offsets at the end of an element; the offset at the first node can be
set using the following code
MyFrame.Elements(1).Offset(1)=Array(1.0,0.0,0.0)
Adding Elements
A new element is added to the frame using the AddElement method of the Elements
collection. This method accepts up to six parameters that specify either the nodes at each
end of the element or the x, y and z coordinates of the ends in the global coordinate
system. When adding the element via it’s end coordinates the position of the element
will be set using current units of length that are set within the Multiframe application. If
a node already exists at one or both of the specified end points, the element will
automatically be connected to the existing nodes. If an end point does not exist, a new
node will be created at that position. The coordinates of the ends can be specified in
three ways; the first uses only the first parameter of the AddElement method and
specifies the coordinates as an array of six values. The second method uses two
parameters and specifies the coordinates of each end as an array of three values. The
final method uses all six parameters and specifies each component of the end coordinates
separately. For example, the following demonstrates the different methods for adding an
element to a structure by specifying the coordinates at the end of the element.
Dim myEl as Multiframe.Element
With myFrame.Elements
‘Add element between (1,3,0) and (1,8,0)
Set myEl =.AddElement(1,3,0,1,8,0)
End With
When adding an element between two nodes there are also a number of variations on
how the nodes are specified. In this case, the first two parameters can be any
combination of variant values representing a node within the model (i.e. the nodes index
or the nodes object). This is demonstrated in the following code.
Page 46
Chapter 4 Modelling the Frame
With myFrame.Elements
’Add element between nodes 1 and 4
Set myEl =.AddElement(myFrame.Nodes(1), myFrame.Nodes(4))
End With
A number of elements can be created using the AddElements method of the Elements
collection. This method accepts up to six parameters which have the same meaning as
the parameters used by the AddElement method. However, each of these parameters
may be an array of values for each of the new elements, or a single value that will be
applied to each of the new elements.
xVar = Array(0,0,0,-1,1,0,2,1,0)
yVar = Array(5,0,0,4,1,0,7,1,0)
With myFrame.Elements
‘Add element between (1,3,0) and (1,8,0)
Set myEl =.AddElements(xVar, yVar)
End With
In Multiframe only a single element can exist between two specific nodes. When adding
an element to the structure, Multiframe will test for the existence of an element between
the specified nodes and, if such an element exists, a new element will not be created.
Instead the existing element will be returned to the user by the AddElement or
AddElements methods.
Page 47
Chapter 4 Modelling the Frame
Properties
The section type and orientation of an element are referenced via the Section,
Orientation, FlipSectionXX, and FlipSectionYY properties of the Element object.
The Section property identifies the Section object that represents the section currently
allocated to the element. When setting the Section property, the new section can be
specified using a Section object or by its name. In this case Multiframe will search the
section library to locate a matching section. Additional functionality for setting the
section type is provided by the SetSection method described in the next section. The
orientation of the section, expressed in the current angle units, is controlled via the
Orientation property. For sections that are not double symmetric, the orientation
method is complemented by the FlipSectionXX, and FlipSectionYY properties that
provide a means of correctly positioning the section in relation to the element. When
these properties are set true, the orientation of the section will be flipped about the
specified axis. A simple example setting the section type and orientation of an element is
shown below.
Dim myEl as Multiframe.Element
Dim s as string
Page 48
Chapter 4 Modelling the Frame
The moment releases at the end of an element are controlled using the Releases
property or the Element object. This property takes a single parameter that specifies an
end of the member and returns an array of six boolean values representing the release of
the end action in the direction of each degree of freedom. When a value in this array is
set true, a release is applied to the corresponding degree of freedom. As Multiframe only
supports the release of end moments, only the 3rd, 4th and 6th elements of this array are
significant. An example on using end releases follows.
Dim myEl as Multiframe.Element
Page 49
Chapter 4 Modelling the Frame
With myFrame
’Apply offsets to both ends element 2
’Offsets applied 1 unit along length of member
.Elements(2).Offset(1) = Array(1.0,0,0) ‘start
offset
.Elements(2).Offset(2) = Array(-1.0,0,0) ‘end offset
.Elements(2).OffsetsLocal = true
The position of an elements end can be determined using the X, Y and Z properties of the
Element object which each return a single component of the ends position in global
coordinates. The XYZ property provides a faster method of accessing all three
components of an end position and returns the coordinates as an array of three values.
As with the Node property, each of the methods takes a single parameter identifying an
end of the element.
The UserData and UserDataUnits properties enable values other than those defined
within Multiframe to be stored with each element. These properties take a single
parameter identifying separate values to be stored with the element thus allowing any
number of values to be stored with each Element. Furthermore, each value is stored as a
variant data type so that strings, numbers or even arrays may be stored with each user
data entry. To provide compatability of the user data with the handling of units within
Multiframe the type of units associated with each user data entry may be set using the
UserDataUnits property. By default each user data value is assumed to be
dimensionless. A simple example demonstrating these properties if shown below
Page 50
Chapter 4 Modelling the Frame
Finally, the Member property returns the Member object corresponding to the design
member of which the element is a part.
Methods
The SetSection method of the Element object is used to specify the section type of an
element. This method takes up to two parameters that specify the section and optionally
the group in which it is contained. The section can be identified in a number of ways;
the first is simply by the index of the section and the group in which it is contained. In
this case the group can be specified by its index within the sections library, its name or
by passing a SectionGroup object. The second method of setting the section is to use
it’s name. In this case no group is required and Multiframe will search the entire sections
library to locate the sections. The final way of setting the section type is to pass a
Section object. Some typical uses of this method are shown in the following code.
Dim myEl As Multiframe.Element
Dim mySection as Multiframe.Section
Page 51
Chapter 4 Modelling the Frame
A list of loads applied to an element can be obtained using the Loads and
ThermalLoads methods of the Element object. These methods take a single parameter
identifying the load cases that are to be considered when compiling the list of loads.
This parameter is optional, and, if omitted, this method will return all the loads applied to
the element as part of any load case within the frame. The Loads and ThermalLoads
methods return the list of loads as ElementLoadList or ThermalLoadList objects
respectively. The flexibility of these methods is demonstrated below
Dim myEl As Multiframe.Element
Dim myLoadList As New Multiframe.ElementLoadList
Dim myThermLoadList As New Multiframe.ThermalLoadList
Add to list the loads applied in the load case named “Live
Loads”
myLoadlist.Add myEl.Loads(“Live Loads”)
The Element object also provides two methods for transforming an array of values
between global and local coordinates. These methods can transform arrays containing
either 6 or 12 values. The GlobalToLocal method, as the name suggests, transforms
values from the global coordinate system to the elements local coordinates as defined by
the its orientation. Conversely, the LocalToGlobal method transforms values expressed
in the elements local coordinates back to global coordinates. A typical application of
transforming values between coordinate systems is in transforming the displacements
(expressed in global coordinates) at a node to values expressed in terms of an elements
local coordinate system.
Page 52
Chapter 4 Modelling the Frame
Restraints
Each restraint applied to a node within a Multiframe structural model is represented by a
Restraint object. All of the restraints applied to the structural model are listed within a
Restraints collection that is stored as part of the Frame object.
Frame
Restraints (Restraint)
A summary of all the properties and methods of the Restraint object are listed in the
table below.
The Application, Frame, Number, Label and Index properties and the Delete method
are common to many objects and are described in Chapter 2.
Page 53
Chapter 4 Modelling the Frame
Restraining Nodes
A new spring can be attached to a node by calling the AddRestraint method of the
Restraints collection. This method has two parameters that specify the node to which
the restraint is to be attached and the degrees of freedom to be restrained. The node to
which the restraint is applied is passed as a variant parameter and so the node can be
identified using either its index or by using a Node object. The degrees of freedom to be
restrained at a node can be described in three ways. The simplest method is by name,
which allows standard restraints such as rollers, pinned, or rigid restraints to be applied
very easily. Standard restraints can also be identified by an enumerated value of type
mfRestraintType. The last technique allows each degree of freedom to be individually
restrained. The names and enumerated values describing the standard type of restraints
are described later in this section. The following code demonstrates the different
parameters that can be used when adding a restraint to a node.
Dim myRest As Multiframe.Restraint
With = myFrame.Restraints
’Add pinned restraint to node 1
Set myRest
=.AddRestraint(1,Array(True,True,True,False,False,False))
Properties
The Node property of the Restraint object identifies the node to which the restraint is
attached. This property, which provides a reference to a Node object, may also be used
to change the node to which the restraint is applied. This property may be set equal to
any variant value that represents a node.
The degrees of freedom restrained by a restraint are specified via the Code property of
the Restraint object. This property is an array of six Boolean values, each value
corresponding to a degree of freedom at the node to be restrained. When an entry in the
array is set true, the corresponding degree of freedom will be restrained. A degree of
freedom can also be restrained via the DOF property. This property has a single
parameter of type mfDOF that specifies a degree of freedom and has a Boolean value of
true if that degree of freedom is restrained.
Page 54
Chapter 4 Modelling the Frame
x Guide mfRestraintRigidxRoller 6
y Guide mfRestraintRigidyRoller 7
z Guide mfRestraintRigidzRoller 8
mfRestraintRotational 9
mfRestraintUnknown 0
The Global property of a restraint determines if the restraint is applied in the global
coordinate system of the local coordinate system of the node to which the restraint is
applied. All nodes added within Multiframe are by default added in the local coordinate
system and it is advisable not to change this property from the value set by Multiframe.
Springs
A spring attached to a node within a structure is represented by a Spring object. This
object encapsulates all the properties of the spring such as its direction and stiffness. All
the springs utilised in a structural model are contained within the Springs collection
which can be referenced directly from the Frame object using the property of the same
name.
Frame
Springs (Spring)
A summary of the properties of the Spring object are listed in the table below.
Page 55
Chapter 4 Modelling the Frame
The Application, Frame, Number, Label and Index properties and the Delete method
are common to many objects and are described in Chapter 2.
Adding a Spring
A new spring can be attached to a node by calling the AddSpring method of the Springs
collection. This method has three parameters that specify the node to which the spring is
to be attached, the direction in which the spring acts and its stiffness. The node to which
the spring is attached is passed as a variant parameter and so the node can be identified
using either its index or by using a Node object. The second parameter is an enumerated
value of type mfDOF that identifies the degree of freedom in which the spring acts. The
final parameter specifies the stiffness of the spring in terms of the current units of spring
stiffness that are set within the Multiframe application. For example, the following code
demonstrates how springs may be added to a structure.
Dim mySpring as Multiframe.Spring
End With
A number of springs can be added in a single call to the automation interface using the
AddSprings method of the Springs collection. This method takes three parameters that
have the same meaning as those passed to the AddSpring method. However, each of the
parameters may be an array of values, containing a value corresponding to each new
spring, or a single value that will be applied to each of the new springs. Some examples
of how this method may be used are shown in the following script.
Dim mySpringList as New Multiframe.SpringList
Dim myNodeList as New Multiframe.NodeList
Dim stiffness as Variant
const DtoR = 3.14159/180.0 ‘Factor to convert
degrees to radians
With myFrame.Springs
End With
Properties
The Spring object encapsulates the data describing a joint spring within a Multiframe
structural model. This data, which includes information describing the node to which the
spring is attached, the direction of the spring and its stiffness, can be access via the
properties of this object.
Page 56
Chapter 4 Modelling the Frame
The Node property of the Spring object identifies the node to which the spring is
attached. This property, which provides a reference to a Node object, may also be used
to change the node to which the spring is applied. It can be set equal to any variant value
that can be used to identify a node.
The direction in which the spring acts is specified by the DOF property of the Spring
object. This property is an enumerated value of type mfDOF. Linear springs are applied
with a DOF of mfDOFx, mfDOFy or mfDOFz while torsional springs are specified
with a DOF of mfDOFthetax, mfDOFthetay or mfDOFthetaz. The axes to which
these degrees of freedom refer are specified by the Global property. This Boolean
property is set true then the spring is acting in the direction of the global coordinate axes.
If the Global property is false, the spring is directed along the local axes of the node to
which the spring is attached. The direction and axes may also be specified using the
Kind property. This property is a character string describing the direction of spring and
the axes to which the load is applied.
The stiffness of a spring is stored in the Value property of the Spring object. This
property describes the spring’s stiffness in terms of the spring or torsional spring units
currently set within the Multiframe application. An example of how these properties
may be changed is as follows
Dim mySpring as Multiframe.Spring
Node Linking
Joint linking or master/slave grouping in a model is represented using the
NodeLinkGroup object. This object encapsulates all the properties of the linked group
of nodes such as which degrees of freedom are linked, the linked nodes and the name of
the group. All the joint linking groups in a structural model are contained within the
NodeLinkGroups collection which can be referenced directly from the Frame object
using the property of the same name.
Frame
NodeLinkGroups (NodeLinkGroup)
A summary of all the properties and methods of the NodeLinkGroup object are listed in
the table below.
Page 57
Chapter 4 Modelling the Frame
In addition, the Application, Frame, Number and Index properties as well as the
Delete method are common to many objects and are described in Chapter 2.
The following code demonstrates how to add a group of linked nodes to the frame. In
this example, all the nodes at y=4.5 are linked together to form a floor with rigid in-plane
behaviour.
Page 58
Chapter 4 Modelling the Frame
dof(1) = True
dof(2) = False
dof(3) = True
dof(4) = False
dof(5) = True
dof(6) = False
In this example to Find method of the Nodes collection is used to select the list of nodes
to be linked. The Find method is common to most collections and lists in the Multiframe
Object Model. It is used to find all the items in the collection or list with a property that
meets a specified criterion. In this instance, this method has been used to find all the
nodes with a y-coordinate lying between 4 and 5. The Find method is described in detail
in Chapter 10.
Properties
The Nodes property of the NodeLinkGroup object returns a NodeList object
containing each of the nodes in the linked group. This property can also be used to set
the nodes in the group and can be set equal to any value that represents one or more
nodes such as a NodeList object. The master node for the linked group is identified via
the MasterNode property. This property returns the Node object representing the
master node. This property can be used to set the master node and can be set equal to
any value used to represent a single node such as it’s index or a Node object.
Dim myGroup As Multiframe.NodeLinkGroup
Dim myNodeList As New Multiframe.NodeList
Page 59
Chapter 4 Modelling the Frame
Methods
Nodes may be added or removed from the linked group using the AddNodes and
RemoveNodes methods of the NodeLinkGroup object. These methods take a single
variant parameter that specifies the nodes to be added or removed from the group. A
simple example demonstrating the various parameters that can be passed to these
methods is shown below.
Dim mylist As New Multiframe.NodeList
mylist.Add "20-30"
With mfApp.Frame.nodeLinkGroups(1)
’Add nodes to linked group
Call .AddNodes(1) 'Add node by index
Call .AddNodes("2-9,12") 'Add nodes listed by index
Call .AddNodes(mfApp.Frame.Nodes(10)) 'Add node using node
object
Call .AddNodes(mylist) ‘Add nodes using list
End With
Node Masses
In Multiframe4D, a joint mass attached to a node within a structure is represented by a
NodeMass object. This object encapsulates all the properties of the mass such the node
to which it is attached and the mass associated with each degree of freedom. All the
nodal masses in a structural model are contained within the NodeMasses collection that
can be referenced directly from the Frame object using the property of the same name.
Frame
NodeMasses (NodeMass)
A summary of all the properties and methods of the NodeMass object are listed in the
table below.
Page 60
Chapter 4 Modelling the Frame
The Application, Frame, Number, Label and Index properties as well as the Delete
method are common to many objects and are described in Chapter 2.
Page 61
Chapter 4 Modelling the Frame
End With
In this example, the Delete method of the NodeMassList object is used to remove all
node masses from the frame. In general this will be much faster than deleting each of the
individual node masses as only a maximum of three calls across the Multiframe
automation interface are required.
Properties
The Node property of the NodeMass object identifies the node to which the mass is
applied. This property, which provides a reference to a Node object, may also be used
to change the node to which the mass is attached.
The magnitude of the mass applied to a node can be referenced via two properties of the
NodeMass object. The Mass property accepts a single parameter identifying a nodal
degree of freedom and returns the magnitude of the mass associated with the specified
degree of freedom. The Masses property returns an array of six (6) values; each entry
in the array corresponds to the mass acting in each of the nodal degrees of freedom. An
example of how these properties would be used is shown in the following script.
Page 62
Chapter 4 Modelling the Frame
GroupSets
Each group set defined for a structural model is contained by the GroupSets collection
stored within the Frame object. This collection is referenced via the GroupSets
property of the Frame object.
Frame
GroupSets (GroupSet)
The properties and method of the GroupSet object are summarised in the table below.
The Application, Frame, Index and Index properties in addition to the Delete method
are common to many objects and are described in Chapter 2.
Each GroupSet object in this collection stores all the loads applied to the frame by that
load case. These loads are contained within one of four collections that store the joint
loads, prescribed displacements, elements loads or thermal loads.
GroupSets (GroupSet)
Groups (Group)
Page 63
Chapter 4 Modelling the Frame
Properties
The name of a group set is referenced via the Label property of the GroupSet object
that stores the name of the set as a string.
The type of grouping allowed within the group set is obtained from the Exclusive
property of the GroupSet object. This property is a Boolean value which is equal to true
when exclusive grouping is to be applied to the groups within this set.
The Groups property provides access to the collection storing the groups defined within
the group set. The use and content of these objects and collections is described in
following sections of the chapter.
Groups
A groups of element and nodes within a group set is represented using the Group object.
This object encapsulates all the properties of the group such as the name and colour of
the group. The groups defined within a group set are contained within a Groups
collection that can be referenced directly from a GroupSet object using the property of
the same name.
A summary of all the properties and methods of the Group object are listed in the table
below.
Page 64
Chapter 4 Modelling the Frame
In addition, the Application, Frame, Number and Index properties as well as the
Delete method are common to many objects and are described in Chapter 2.
Creating a Group
A new group is added to a group set using the AddGroup method of the Groups
collection. This method accepts three parameters that specify the name of the group, the
grouped nodes and the grouped elements. The nodes and elements in the group are
specified using a variant parameter and so any value representing a group of nodes or
group of elements can be used to specify these lists. Typically this will be either an array
of indices or a list object or can be omitted if the group is to be created with no content.
The AddGroup method returns the Group object referencing the new group added to the
frame.
The following code demonstrates how to add a group to the frame. In this example,
elements 1 to 5 are grouped together to
Dim myGroup As Multiframe.Group
Properties
The Nodes property of the Group object returns a NodeList object containing each of
the nodes in the group. This property can also be used to set the nodes in the group and
can be set equal to any value that represents one or more nodes such as a NodeList
object.
Dim myNodeList As New Multiframe.NodeList
With myFrame.GroupSets(“Floors”)
’ Reset nodes in the group
.Group(”Floor 1”).Nodes = myNodeList
Similarly, the Elements property of the Group object returns a ElementList object
containing each of the elements in the group. This property can also be used to set the
elements in the group and can be set equal to any value that represents one or more
elements such as a ElementList object.
With myFrame.GroupSets(“Floors”)
’ Reset elements in the group
.Group(”Floor 1”).Elements = “1-6”
End With
The colour of a group is referenced via the Color property of the Group object. The
property is of type OLE_COLOR.
Page 65
Chapter 4 Modelling the Frame
With myFrame.GroupSets(“Floors”)
.Group(”Floor 1”).Colour = 255 ‘red
.Group(”Floor 2”).Colour = 16711680 ‘blue
.Group(”Floor 3”).Colour = 65280 ‘green
End With
The name of the group is referenced via the Label property of the Group object.
OLE_COLOR
The OLE_COLOR data type represents a colour as a BGR (Blue, Green,
Red) value. The OLE_COLOR value of a colour specified by its red, green
and blue components (each of which has a value from 0 - 255) is determined
using the following expression:
Black 0
Grey 8421504
White 16777215
Red 255
Green 65280
Blue 16711680
Magenta 16711935
Cyan 16776960
Methods
Nodes may be added or removed from the group using the AddNodes and
RemoveNodes methods of the Group object. These methods take a single variant
parameter that specifies the nodes to be added or removed from the group. A simple
example demonstrating the various parameters that can be passed to these methods is
shown below.
Dim mylist As New Multiframe.NodeList
mylist.Add "20-30"
Page 66
Chapter 4 Modelling the Frame
With mfApp.Frame.GroupSets(“Floors”).Group(1)
End With
The manipulation of elements in a group in handled in a similar manner. Elements may
be added or removed from the group using the AddElements and RemoveElements
methods of the Group object. These methods take a single variant parameter that
specifies the elements to be added or removed from the group. A simple example
demonstrating the various parameters that can be passed to these methods is shown
below.
Dim mylist As New Multiframe.ElementList
mylist.Add "20-30"
With mfApp.Frame.GroupSets(“Floors”).Group(“Floor 1”)
End With
Members
The Member object represents a design member within a structure. This object
encapsulates all the properties of a design member such as its position, length, slope,
section and orientation. All the members that are defined within a structure are
contained within the Members collection that is stored as part of the Frame object.
Frame
Members (Member)
A summary of all the properties and methods of the Member object are listed in the table
below.
Page 67
Chapter 4 Modelling the Frame
In addition, the Application, Frame, Number, Label and Index properties as well as
the Delete method are common to many objects and are described in Chapter 2.
Page 68
Chapter 4 Modelling the Frame
Creating Members
A design member in Multiframe is a single element or a group of collinear connected
elements. Elements can be grouped together to form a design member using the Group
method of the Members object. This method requires a single parameter that specifies
the elements to be linked together. This is a variant parameter and so any value
identifying a list of elements will be acceptable such as an array of elements indices or an
ElementList object. A simple example demonstrating this method is shown below.
This example subdivides an element and then groups the resulting elements into a single
member.
Dim myElList As New Multiframe.ElementList
Dim myMbr As Multiframe.Member
’ Subdivide element
Set myElList = myFrame.Elements(1).Subdivide(5)
Properties
The section and its orientation within a member are referenced via the Section,
Orientation, FlipSectionXX, FlipSectionYY properties of the Member object. The
Section property identifies the Section object that represents the section currently
allocated to the member. When setting the Section property, the new section can be
specified using a Section object or by its name. In this case, Multiframe will search the
section library to locate a matching section. Additional functionality for setting the
section type is provided by the SetSection method described in the next section. The
orientation of the section, expressed in the current angle units, is controlled via the
Orientation property. For sections that are not double symmetric, the orientation
method is complemented by the FlipSectionXX, FlipSectionYY properties that provide
a means of correctly positioning the section in relation to the member. When these
properties are set true, the orientation of the section will be flipped about the specified
axis. An example on setting the section type and orientation is shown below.
Dim myMbr as Multiframe.Member
Dim s as string
Page 69
Chapter 4 Modelling the Frame
The length and slope of a member can be determined from the read-only properties
Length, Slope, SlopeXY, SlopeZX, SlopeZY. The Length property returns the length
of the member in the current length units. Note the length of the member is measured
between end points defined by the end offsets and is NOT the distance between the
nodes defining the member. The four methods for returning the slope of the member
return a value in terms of the current angular units set within Multiframe. The Slope
method returns the slope of the member in the X-Y plane and corresponds the slope of
the member displayed in the user interface. The other three slope methods return the
slope of the member in a specific plane. The SlopeXY returns the slope of the member
in the XY plane that is measured from the X to the Y-axes. Similar the SlopeZX and
SlopeZY properties return the slope of the member in the ZX and ZY plane respectively,
with the angle measured from the Z axis.
Dim myMbr as Multiframe.Member
Dim s as string
Methods
The SetSection method of the Member object is used to specify the section type of a
member. This method takes up to two parameters that specify the section and optionally
the group in which it is contained. The section can be identified in a number of ways;
the first is simply by the index of the section and the group in which it is contained. In
this case the group can be specified by its index within the sections library, its name or
by passing a SectionGroup object. The second method of setting the section is to use
its name. In this case no group is required and Multiframe will search the entire sections
library to locate the sections. The final way of setting the section type is to pass a
Section object. Some typical uses of this method are shown in the following code.
Dim myMbr As Multiframe.Member
Dim mySection as Multiframe.Section
Page 70
Chapter 4 Modelling the Frame
The Results method of the Member object provides a means of directly accessing the
results at a member, from a particular analysis, without navigating through the hierarchy
of the Results object. This method takes three parameters; the first is a variant
parameter identifying the load case for which the results are required, the second
identifies the type of analysis. The third parameter is redundant and has been included
for future expansion of the automation interface. The Results method returns an
MemberResult object that encapsulates access to the nodal displacements and reactions.
This object is described in detail in Chapter 7.
The Member object also provides two methods for transforming an array of values
between global and local nodal coordinates. These methods can transform arrays
containing either 6 or 12 values. The GlobalToLocal method, as the name suggests,
transforms values from the global coordinate system to the members local coordinate
system as defined by the members position and orientation. Conversely, the
LocalToGlobal method transforms values expressed in the member local coordinate
system back to global coordinates. A simple example is shown below.
Dim myMbr As Multiframe.Member
Dim r As Variant
Project Details
The ProjectInfo object encapsulates the storage of data providing informative and
descriptive information about the frame such as its title, location designer and the client
for whom the work is been conducted.
Frame
ProjectInfo
A summary of all the properties and methods of the ProjectInfo object are listed in the
table below.
Page 71
Chapter 4 Modelling the Frame
Properties
Most of the properties of the ProjectInfo object are user definable fields describing the
project and the people/organisations involved in the project. A simple example of how
to modify the project details is shown below.
With myFrame.ProjectInfo
.Company = "John Smith Design"
.Designer = "John Smith"
.Checker = "John Smith Jr"
.Title = "My Steel Building"
.JobID = "2001/196"
End With
With mfFrame.Nodes
Set myNodeList = .AddNodes(Array(0.0,5.0),Array(2.5,5.0),0)
End With
or
Dim objNodeList as New Multiframe.NodeList
Dim xArray(1 to 2) as double
Dim yArray(1 to 2) as double
A further benefit of using lists is that the properties of the items can be set much more
readily. For example, if all the nodes added by the above code were to be pinned, then
this could be done using the line of code
myNodeList.Pinned = true
Page 72
Chapter 4 Modelling the Frame
Of course adding nodes and then connecting them with elements is not necessary in the
Multiframe automation interface, elements can be added directly and the appropriate
nodes will be created automatically. A more efficient example of adding a small portal
frame might be coded as
Dim objElList as New Multiframe.ElementList
Dim x1,y1 as Variant
Dim x2,y2 as Variant
Dim width,hcol,hapex as Double
Page 73
Chapter 5 The Load Objects
Load Cases
Each load case applied to a structural model is contained by the LoadCases collection
stored within the Frame object. This collection is referenced via the LoadCases
property of the Frame object. Alternatively, this collection can be accessed directly
from the Multiframe Application object via its LoadCases property. The properties
and method of the LoadCase object are summarised in the table below.
The Application, Frame, Index and Index properties in addition to the Delete method
are common to many objects and are described in Chapter 2.
Load cases are categorized as static, combined or self-weight. While each of these is
defined by slightly different information, the LoadCase object is used to describe all
three types of cases. The type of a load case is defined when it is created and cannot be
changed. If the user accesses a property of the LoadCase object that is not relevant to
the type of the load case, an error will be returned.
Page 75
Chapter 5 The Load Objects
Each LoadCase object in this collection stores all the loads applied to the frame by that
load case. These loads are contained within one of four collections that store the joint
loads, prescribed displacements, elements loads or thermal loads.
LoadCases (LoadCase)
NodeLoads (NodeLoad)
NodePreDisps (NodePreDisp)
ElementLoads (ElementLoad)
ThermalLoads (ThermalLoads)
Properties
The name of a load case is referenced via the Name property of the LoadCase object
that stores the name of the load case as a string.
The type of a particular load case can be determined from the Type property of the
LoadCase object. This property is an enumerated value of type mfLoadCaseType
with values of mflcStatic, mflcSelfWeight and mflcCombined. Each of the different
load case types are described below. As noted above, this is a read only property as the
type of load case cannot be changed from that allocated when the load case was created.
Static Cases
A static load case is created by adding a load case to the LoadCases collection using the
AddCase method of this collection. When adding the load case it must be specified as a
load case of type mflcStatic. For example,
Dim myCase as Multiframe.LoadCase
Self-Weight Cases
Adding a new load case of type mflcSelfWeight to the LoadCases collection creates a
self-weight load case.
Page 76
Chapter 5 The Load Objects
‘Setting accelerations
myLoadCase.Acceleration(1) = 0.0 ‘Set x-component
myLoadCase.Acceleration(mfDOFy) = 0.0 ‘Set x-component
Combined Cases
Adding a new LoadCase object of type mflcCombined to the LoadCases collection
creates a combined or factored load case.
Dim myLoadCase as Multiframe.LoadCase
Page 77
Chapter 5 The Load Objects
The load case factors may also be accessed via the Factors property of the LoadCase
object. This variant property returns an array of values representing the factors applied
to each load case contained within the frame. For example;
Dim myFactors as Variant
Node Loads
A NodeLoad object represents a force or moment load applied to a node within the
structure. All the nodal loads applied in a particular load case are stored in a
NodeLoads collection. These loads can be accessed via the NodeLoads property of
the LoadCase object. The properties and methods of the Node object are listed below.
The Application, Frame, Number, Label and Index properties as well as the Delete
method are common to many objects and are described in Chapter 2.
Page 78
Chapter 5 The Load Objects
With myFrame.LoadCases(1)
End With
The AddLoad method can also take an extra optional parameter that specifies if the load
is to be applied in the global or the local nodal coordinate system. By default, all node
loads are added in the local nodal coordinate system.
Groups of nodal forces can be created using the AddLoads method of the NodeLoads
collection. This method returns a NodeLoadList containing each of the loads added to
the frame. The parameters of this method correspond to the parameters of the AddLoad
method except that each parameter may be either an array, containing values for each of
the new loads, or a single value that will be applied to each of the new loads. Several
examples of how this method may be used are as follows:
Dim myLoads as New Multiframe.NodeLoadList
Dim myNodeLoads as Multiframe.NodeLoads
Dim myVar as Variant
NodeLoad Properties
A nodal load can be modified via the NodeLoad object. This object has properties
describing the node to which the load is applied, the direction, magnitude and the axis to
which the loading is orientated.
The node at which the load is applied is identified by the Node property of the
NodeLoad object. This property returns the Node object corresponding the node at
which the load is applied. This property may be set to a new value using any variant
value representing a node.
Page 79
Chapter 5 The Load Objects
The DOF property controls the direction in which the load is applied. The property is an
enumerated value of type mfDOF. Nodal force loads are applied with a DOF set to
mfDOFx, mfDOFy or mfDOFz that describes the direction in which the load is applied.
Nodal moment loads are specified with a DOF of mfDOFthetax, mfDOFthetay or
mfDOFthetaz. The axes to which these degrees of freedom refer are specified by the
Global property. If this Boolean property is true then the load is applied in the direction
of the global coordinate axes. If the Global property is false, the load is directed along
the local nodal axes that are specified by the nodal orientation. The direction and axes of
the loading may also be specified using the Kind property. This property is a character
string describing the direction of loading and the axes to which the load is applied.
The magnitude of the load is stored in the Value property of the NodeLoad object. The
value of this property describes the magnitude in terms of the force or moment units
currently set within the Multiframe application. An example of how these properties
may be changed is as follows
Dim myLoad as Multiframe.NodeLoad
Prescribed Displacements
The NodePreDisp object represents a prescribed displacement applied to a node as part
of a load case. All the prescribed displacements applied in a particular load case are
stored in a NodePreDisps collection. These displacements can be accessed via the
PrescribedDisps property of the LoadCase object.
The NodePreDisp object is identical to the NodeLoad object except that the Value
property of the NodePreDisp object returns a displacement or rotation instead of a force
or a moment. The value of the displacement is specified in the current displacement or
angular displacement units. Similarly, new displacements are added to a load case using
the AddDisp or AddDisps methods of the NodePreDisps collection and these methods
have the same syntax as the AddLoad and AddLoads methods of the NodeLoads
collection. For example, the following code adds two prescribed displacements to the
first load case.
Dim myLoad as Multiframe.NodePreDisp
Dim myNode as Multiframe.Node
With myFrame.LoadCases(1)
End With
Page 80
Chapter 5 The Load Objects
Element loads
The ElementLoad object represents a point or a distributed load applied to an element
within the structure as part of a load case. All the Element loads applied by a particular
load case are stored in an ElementLoads collection within the LoadCase object. These
loads can be accessed via the ElementLoads property of the LoadCase object. The
properties and methods of the ElementLoad object are listed below.
The Application, Frame, Number, Label and Index properties as well as the Delete
method are common to many objects and are described in Chapter 2.
For example, the following code adds a point load to element number 12. The load is
applied as part of the third load case and is positioned 1.5 units from the start of the
element. It is directed parallel to the global y-axis and has a magnitude of 20 units.
Page 81
Chapter 5 The Load Objects
With myFrame.LoadCases(1).ElementLoads
End With
Remember that the units used in adding this load are those currently specified within the
application.
The next four parameters specify the magnitudes (F1 and F2) and distances (Distance1
and Distance2) of the loads from either end of the member. These must be specified in
the current force/moment and length units. The interpretation of these quantities is
dependent upon the shape of load been added to the element. The definition of these
parameters for each type of load shape is shown in the diagram below. The parameters
not required by a particular load shape will be ignored.
Uniform distributed load
F1
F1 F2
F1
F2
F1
Distance1 Distance2
Page 82
Chapter 5 The Load Objects
The final parameter of the AddLoad method specifies if the load is to be applied in the
global or local element coordinate system. By default, all element loads are applied in
the elements local coordinate system.
The small script shown below demonstrates how the AddLoad method may be used to
add the different types of loads.
Dim myLoad as Multiframe.ElementLoad
Dim myElLoads as Multiframe.ElementLoads
Dim L as double
With myElLoads
End With
The AddLoad method can also be used to add a point load to an element by specifying
the shape of the load as mfLoadshapePoint. In this case, the magnitude is specified by
the parameter F1 while the loads position along the element is set using the Distance1
parameter. A simple example follows.
Dim load as Multiframe.ElementLoad
Dim myLoads as Multiframe.ElementLoads
Dim L as double
End With
Page 83
Chapter 5 The Load Objects
With myElLoads
End With
The first parameter of the AddPointLoads and AddLoads methods is a variant
parameter identifying the element to which the loads are to be applied. This parameter
may specify the elements by using an integer index, an array of integer indices, an
Element object, an Element List, or an Elements collection.
The element to which the load is applied is identified by the Element property of the
ElementLoad object. This property returns the Element object corresponding the
element at which the load is applied.
The DOF property controls the direction in which the load is applied. The property is an
enumerated value of type mfDOF. The axes to which these degrees of freedom refer are
specified by the Global property. If this Boolean property is true then the load is applied
in the direction of the global coordinate axes. If the Global property is false, the load is
directed along the local element axes that are specified by the direction and orientation of
the element. The direction and axes of the loading may also be specified using the Kind
property. This property is a character string describing the direction of loading and the
axes to which the load is applied.
The shape of an element load is specified by the Shape property of the element load that
is an enumerated value of type mfLoadShape. This enumerated type has values
corresponding to uniform, linearly varying, triangular and tri-linear distributed loads as
well as a value representing a concentrated point load. The magnitudes of the loads that
describe this shape of load are referenced by the Value1 and Value2 properties of the
ElementLoad object. Similarly, the two distances that may be used to describe a
particular shape of load as contained by the Dist1 and Dist2 properties the
ElementLoad object. The values of these properties are specified in terms of the current
force units (Value1, Value2) and in the current length units (Dist1, Dist2) as set within
the Multiframe application. An example of how these properties may be changed is as
follows
Page 84
Chapter 5 The Load Objects
Thermal Loads
The ThermalLoad object represents a thermal load applied to the structure. All the
thermal loads applied in a particular load case are stored in a ThermalLoads collection
within the LoadCase object. These loads can be accessed via the ThermalLoads
property of the LoadCase object. The methods and properties of the ThermalLoad
object are summarised in the following table.
The Application, Frame, Number, Label and Index properties as well as the Delete
method are common to many objects and are described in Chapter 2.
Page 85
Chapter 5 The Load Objects
Multiple thermal loads can be created using the AddLoads method of the
ThermalLoads collection. This method returns a ThermalLoadList containing each of
the loads added to the specified load case. Each parameter in the AddLoads method
may be either an array, containing values for each of the new load, or a single value that
will be applied to each new load. Several examples of how this method may be used are
as follows:
Dim myLoads as New Multiframe.ThermalLoadList
Dim myVar as Variant
End With
The first parameter of the AddLoads method is a variant parameter identifying the
element to which the loads are to be applied. This parameter may specify the elements
by an integer index, an array of integer indices, an Element object, an Element List, or
an Elements collection.
Page 86
Chapter 5 The Load Objects
The element at which the load is applied is identified by the Element property of the
ThermalLoad object. This property returns the Element object corresponding the
element at which the load is applied.
The DOF property controls the direction in which the temperature gradient is applied.
The property is an enumerated value of type mfDOF. Although this enumerated type
has six permissible values, thermal loads may only be specified with values of mfDOFy
or mfDOFz that correspond to a temperature gradient applied in the directions of the
elements local y and z axes. The direction of the thermal loading may also be specified
using the Kind property. This property is a character string describing the direction in
which the load is applied.
The magnitudes of the temperatures at each face of the element are referenced by the
Ttop and Tbottom properties of the ThermalLoad object. The Ttop property specifies
the temperature on the face of the element lying in the positive plane of the local element
axis in which the thermal load is applied. Conversely, Tbottom is the temperature at the
face in the negative plane. The values of these properties are specified in terms of
temperature units currently set within the Multiframe application.
The Depth property of the ThermalLoad object specifies the depth over which
temperature gradient is applied. This is described using the current displacement units.
The thermal coefficient used to model the material in the thermal load is referenced via
the Coeff property that is expressed using the current units of thermal expansion
The LoadCase, Frame and Application properties of the thermal load object identify
its parent objects. These properties cannot be modified.
Deleting Loads
A load is deleted from the model by calling the Delete method of the object that
represents that load. For example
‘Delete a node load
MyFrame.LoadCases(1).NodeLoads(2).Delete
Page 87
Chapter 5 The Load Objects
In this code, the Loads properties of the Node object return lists of all the loads applied
to node 6. The code is this example is unnecessarily long and can be reduced to a single
line as there is no real need to declare the NodeLoadList object. An improved example
that deletes all the loads applied to a specified node and element is as follows
‘Delete all loads attached to node 6
MyFrame.Nodes(6).Loads.Delete
MyFrame.Nodes(6).PreDisps.Delete
Note that loads will automatically be deleted from the frame when their parent node or
element is deleted.
With myFrame.LoadCases(1).NodeLoads
End With
Refer to the Multiframe User Manual for a description of the expressions and variables
that can be evaluated by Multiframe.
Page 88
Chapter 6 Automating Analysis
The Application and Frame properties are common to many objects and are described
in Chapter 2 of this manual.
The settings for each analysis are stored in the four objects; LinearSettings,
NonlinearSettings, ModalSettings and TimeHistorySettings, which are all accessible
from the Analysis object via properties of the same names.
Analysis
LinearSettings
NonlinearSettings
ModalSettings
Page 89
Chapter 6 Automating Analysis
The analyses to be performed are specified by the Linear, Nonlinear, Modal and
TimeHistory properties of the Analysis object. Each of the selected analyses will be
performed when the Analyse method is called.
Call MyFrame.Analysis.Analyse()
This method takes a single optional parameter to specify if the analysis is to perform a
three dimensional analysis. If this parameter is not specified or set equal to false,
Multiframe will automatically determine if the frame is suitable for a two dimensional
analysis and perform the analysis of the frame as a two dimensional structure.
The Application object also features an Analyse method that performs an analysis with
the current analysis settings.
Call mfApp.Analyse()
To perform a static linear analysis of a structure, the Linear property of the Analysis
object must be set equal to true. If this property is not set true, a linear static analysis
will not be performed when the analysis is executed
myFrame.Analysis.Linear = true
Call myFrame.Analysis.Analyse()
Page 90
Chapter 6 Automating Analysis
The Application and Frame properties are common to many objects and are described
in Chapter 2.
The non-linear effects to be considered in an analysis are set using a number of Boolean
properties that are set equal to true if the non-linear effect is to be modelled in the
analysis. Axial shortening effects are controlled using the AxialShortening property
while the P-δ and P-Δ effects are set using the pLittleDelta and pBigDelta properties
respectively. Tension and Compression only effect are activated using the TensionOnly
property.
The number of loading increments to be used in the analysis of a load case is specified
by the Increments property of the NonlinearSettings object. For each increment, the
minimum and maximum number of iterations is limited by the values of the
MinIterations and MaxIterations properties. The Tolerance property stores the
convergence tolerance to be used in the analysis that is tested using the convergence
norm identified by the Norm property. This property is an enumerated value of type
mfConvergenceNorms with values of mfConvergenceForce (1),
mfConvergenceDisplacememt (2) and mfConvergenceBoth (3). The level of
reporting is also specified by an enumerated property, Reporting, which is of type
mfReportLevels. This has values of mfReportingNone (1), mfReportingBrief (2),
mfReportingDetailed(3) and mfReportingFull(4).
The load cases to be analysed as part of the nonlinear analysis are specified using the
LoadCases property of the NonlinearSettings object. While this property returns a
LoadCaseList object listing the load cases to be analysed, it can be set using a variant
value representing a list of load cases.
A non-linear static analysis is performed by calling the Analyse method of either the
Analysis or Application objects provided the NonLinear property of the Analysis
object is set equal to true. As an example, consider the following code to perform a
nonlinear analysis.
Page 91
Chapter 6 Automating Analysis
Modal Analysis
A modal analysis is performed by setting the Modal property of the Analysis object
equal to true and then calling the Analyse method. The settings for a modal analysis are
contained within the ModalSettings object. This object has five properties that control
the analysis which are listed in the following table.
Page 92
Chapter 6 Automating Analysis
The Application and Frame properties, which are common to many objects in the
Multiframe Object model, are described in Chapter 2.
The Modes property is used to control the number of mode shapes determined by the
analysis. Each mode shape will be computed using a maximum number of iterations
specified by the MaxIterations property. The iteration of each load increment in the
analysis will be performed to the convergence tolerance set by the Tolerance property.
The other two properties of the ModalSettings object control the type of mass
distribution used in the analysis. If a lumped mass formulation is required, the
LumpedMass property must be set true, else a distributed mass formulation can be
employed by setting the DistributedMass property to true. Note that these two
properties are mutually exclusive, setting one of them equal to true will automatically set
the other property to false. The following script demonstrates how to perform a modal
analysis.
Dim mySettings as Multiframe.ModalSettings
The Application and Frame properties, which reference the parent objects, are common
to most objects in Multiframe and are described in Chapter 2.
Page 93
Chapter 6 Automating Analysis
These two properties control the type of formulation to be used in computing the element
mass matrices. If a lumped mass formulation is required, the LumpedMass property
must be set true, else a distributed mass formulation can be employed by setting the
DistributedMass property to true. As with the modal settings, these properties are
mutually exclusive. The following script demonstrates how to perform a time history
analysis.
Dim mySettings as Multiframe.TimeHistorySettings
Page 94
Chapter 7 Results Objects
Properties
The Results object has three properties that provide access to the results of linear, non-
linear and modal analyses. Each of these sets of results is stored in separate objects as
shown in the diagram below.
Results
LinearResults
ResultCases (ResultCase)
NonlinearResults
NodeResults (NodeResult)
ModalResults
ElementResults (ElementResult)
MemberResults (MemberResult)
Page 95
Chapter 7 Results Objects
Each of the objects storing the results from the different types of analyses contains a
collection of ResultCase objects. Each ResultCase object stores the results for a
single load case or, in the case of the modal analysis, the results for a single mode shape.
Methods
The Case method of the Results object provides a means of obtaining the results for a
particular analysis without having to navigate the object hierarchy. This method takes
two parameters; the first is a variant parameter identifying the load case. For modal
analyses, this parameter identifies the index of the mode shape. The second parameter in
an enumerated value of type mfAnalysisType, that specifies the analysis for which the
results are required. This method returns a reference to a ResultCase object containing
the desired information.
Dim myResults As Multiframe.ResultCase
With myFrame.Results
End With
The Results object provides another method to complement the Case method that
determines if the results for a particular case have been computed by an analysis. The
Solved method takes the same parameters as the Case method and returns a value of true
if the specified analysis has been performed. The above example could be recoded as
Dim myResults As Multiframe.ResultCase
With myFrame.Results
End With
Result Cases
For any of the analyses performed by Multiframe, the ResultCase object encapsulates a
single set of data describing the displacements of a frame and the resulting actions within
its members. For a linear or non-linear static analysis, the ResultCase object contains
the results for the analysis of a single load case. A collection of ResultCase objects is
stored by each of the LinearResults and NonlinearResults objects, each item in these
collections corresponds directly to the results from the analysis of each load case applied
to the model. The modal analysis results, stored in the ModalAnalysis object, are also
contained within a ResultCases object. In this case, each item in the collection
corresponds to a single mode. The properties of the ResultCase object are listed below.
Page 96
Chapter 7 Results Objects
The results at each node in the frame are stored as a collection of NodeResult object.
Similarly the results for each element and member are stored in collections of
ElementResult and MemberResult objects. These three collections are reference from
the ResultCase object via the properties NodeResults, ElementResults and
MemberResults.
The Solved property of the ResultCase object is a Boolean property that returns true if
the results of this case have been computed.
An identical structure is provided to access the results of non-linear static analyses. The
Nonlinear property of the Results object returns a reference of a NonlinearResults
object that contains a collection of ResultCase objects, each corresponding directly to
the load cases applied to the frame.
Page 97
Chapter 7 Results Objects
With myFrame.Results
End With
A ResultCase object for either a linear of non-linear analysis will exist for each load
case in the model irrespective of whether the case has been analysed. The Solved
property of the ResultCase object returns a value of true if the particular case has been
analysed and the results are available.
Modal Results
The results of a modal analysis are accessed via the Modal property of the Results
object. This property returns a reference to a ModalResults object that contains the
results for all the mode shapes computed by the analysis. The properties of the
ModalResults object are outlined in the table below.
The modal displacements are stored in a ResultCases collection object; each item in the
collection corresponds to a single mode shape computed by the analysis. These results
are referenced as follows.
Page 98
Chapter 7 Results Objects
Nodal Results
The NodeResult object encapsulates the results at a node for a particular analysis. The
properties of this object, which are all read-only, return the displacement of the node and
the resultant reactions. The properties of this object are listed in the table below.
Page 99
Chapter 7 Results Objects
The Application and Frame properties are common to many objects and are described
in Chapter 2. The NodeResult object has no methods.
The NodeResult object can be obtained for a node even if the specified analysis has not
been performed. As such, the Solved property has been provided to determine if the
results are available. This property returns true if the results for the node are available
for the associated type of analysis. Trying to access many other properties of this object
will return and error if the results have not been solved for. As such, it is good
programming practice to determine if the results are available prior to accessing the other
properties of the NodeResult object.
The displacements at a node can be obtained in three different ways using the properties
of the NodeResult object. The appropriate means of access if often dependent upon the
script in which the values are used. The first technique for accessing the displacements
is via the individual properties representing the displacement in each degree of freedom.
The translation of the node is obtained via the properties dx, dy and dz while the
rotational displacements are specified by the properties thetax, thetay, thetaz. These
properties all return the displacement of the node in terms of the global coordinate
system.
The second method of accessing the displacements at a node is using the Displacement
property of the NodeResult object. This property returns the displacement for a
specified degree of freedom. The distinction of this member as a property and not a
method is purely academic since it is read only. However, it is a special type of property
that takes a single enumerated parameter identifying the degree of freedom.
Page 100
Chapter 7 Results Objects
The final means of accessing the displacements is using the Displacements property.
This property returns a variant containing an array of six real numbers that are the
displacements for each degree of freedom at the node. This property is the fastest
method of accessing all the displacements at a node, as it only requires a single call to the
automation interface. The displacements returned by any of these properties is specified
in terms of either the displacement or rotation units currently in use by the Multiframe
application. The following example demonstrates the use of all three techniques of
accessing the displacements in determining the total distance moved by a node.
Dim myResult As Multiframe.NodeResult
Dim dist As Double
Dim i As Long
Dim myVar As Variant
Endif
A similar interface is also provided to access the reactions at a node. The properties, Rx,
Ry, Rz and Mx, My, Mz return the reactions in each degree of freedom. Alternatively
the Reaction property returns the reaction for a specified degree of freedom while the
Reactions method returns an array of the reactions at the node. The values returned by
each of these properties is specified in terms of either the force or moment units currently
in use by the Multiframe application.
The Node property of the NodeResult object returns a reference to a Node object that
identifies the node to which the results apply.
The analysis used to generate the results can be determined from the Analysis property
of the NodeResult object. This property returns an enumerated value of type
mfAnalysisType.
Element Results
The actions and displacement of a single element resulting from an analysis are
represented in the automation interface by the ElementResult object. The properties of
this object, which are all read-only, are listed in the table below. The object also
provides methods for accessing the actions at any position along the element and for
constructing diagrams of the distribution of actions along the element. These properties
and methods are as follows;
Page 101
Chapter 7 Results Objects
Page 102
Chapter 7 Results Objects
The Application and Frame properties are common to many objects and are described
in Chapter 2.
Properties
As for nodal results, the ElementResult object can be obtained for an element even if
the specified analysis has not been performed. As such, the Solved property has been
provided to determine if the results are available. This property returns true if the results
for the node are available for the associated type of analysis. Trying to access many
other properties of this object will return and error if the results have not been solved for.
As such, it is good programming practice to determine if the results are available prior to
accessing the other properties of the ElementResult object.
The displacements at the end of an element can be referenced using several properties of
the ElementResult object. The appropriate method will be determined by how the
value is used by the script. The first technique for accessing the displacements is via the
individual properties representing the displacement in each degree of freedom at the end
of the element. The translation of the element end is obtained via the properties dx, dy
and dz while the rotational displacements are specified by the properties thetax, thetay,
thetaz. Each of these properties takes a single parameter specifying an end of the
element and all return the displacement of the elements end in the elements local
coordinate system.
A third technique for accessing the displacements is using the EndDisps property. This
property returns a variant containing an array of real numbers containing either the
displacements for each degree of freedom at a specified end of an element or an array of
values for the displacements at all of the elements degrees of freedom. This property is
the fastest method of accessing all the displacements at the ends of an element, as it only
requires a single call to the automation interface to obtain the displacements of each of
the elements degrees of freedom.
The displacements returned by any of these properties is specified in terms of either the
displacement or rotation units currently in use by the Multiframe application. The
following example demonstrates the use of all three techniques of accessing the
displacements in determining the total distance moved by a node.
Page 103
Chapter 7 Results Objects
Endif
A similar interface is also provided to access the actions at the ends of the element. The
properties, Px, Vy, Vz and Tx, My, Mz return the actions at each end of the member.
These may also be returned by referencing a particular degree of freedom using the
EndActions property while the EndActions method returns an array of the end action at
a specified end of the element or an array of values for all of the elements degrees of
freedom. The values returned by each of these properties is specified in terms of either
the force or moment units currently in use by the Multiframe application.
Two properties of the ElementResult object allow the user to quickly determine if the
element is in tension or compression without worrying about sign conventions. The
InTension property will return true if the element is in axial tension while the
InCompression property returns a value of true if the element is in axial compression.
Methods
The GetAction and GetActions methods of the ElementResult object provide access to
the displacements and actions along an element. The GetAction method returns the
value of a specified action or displacement at a specified location along the member.
The GetActions method extends this functionality and returns an array of values for the
action at a number of specified locations. For example, the following code demonstrates
how to determine the moments at quarter points along an element.
Page 104
Chapter 7 Results Objects
Endif
The maximum values of an action or displacement along an element can be obtained
using the MaxAction and MaxActions properties of the ElementResult object. The
MaxAction method returns the maximum value for a single action while the
MaxActions method is used to compute the maximum value of a list of actions. The
methods each take two parameters; the first specifies the action or actions to be
considered. The second parameter in an enumerated value of type mfSign that identifies
whether to maximum negative, positive or absolute value of the action is to be computed.
The following example demonstrates using these methods to compute the design actions
for an element
Page 105
Chapter 7 Results Objects
Mz = myVar[1]
My = myVar[2]
Vy = myVar[3]
Vz = myVar[4]
P = myVar[5]
Endif
The CopyPlot method provides a simple way of copying a graphic image of a specific
actions diagram to the Windows clipboard. This image can then be pasted directly into a
3rd party application. This method takes five parameters which specify inorder, the
action to be plotted, the width of the image in pixels, the height of the image in pixels, a
boolean value indicating if the maximum, minimum and end actions are to be displayed
on the diagram and lastly another boolean value indicating if a heading should be
included in the image. This heading includes the name of the load case, the number of
the element, the elements section, the name of the action and it’s units. The following
sample code shows how a bending moment diagram can be copied to the clipboard.
Dim myResult As Multiframe.ElementResult
‘Build chart
Endif
Page 106
Chapter 7 Results Objects
The locations of actions along the element used to construct a plot of an action such as a
bending moment or shear diagram can be obtained using the GetPlotLocations method
of the Element object. This function takes single parameter that specifies the action to
be plotted and returns an array containing the distances along the member at which the
action needs to be computed to construct the diagram of the specified action. This array
can be passed directly to the GetActions method to obtain to values of the actions at each
location in the plot. This information can then be used to construct a custom plot of the
data. The example that follows demonstrates how to construct a chart that plots the
bending moments along the major axis of an element.
Dim myResult As Multiframe.ElementResult
Dim Mz,My,Vz,Vy,P as Double
Dim vLocations as Variant
‘Build chart
Endif
Member Results
When designing members it is necessary to determine the actions acting upon the
member. Rather that require the actions be determined for the elements forming the
member, the automation interface provides a direct interface to the actions within a
design member via the MemberResult object. The properties and methods of this
object are the same as those for the ElementResult object except that the results apply
to a specific design member rather than element.
Page 107
Chapter 8 Sections Library
SectionsLibrary
SectionGroups (SectionGroup)
Sections (Section)
Materials (Material)
SectionsLibrary Object
The sections library open within Multiframe is represented via the SectionsLibrary
object. This object contains a hierarchy of objects representing the groups, sections and
materials stored within the library. In addition, this object is responsible for managing
the loading and saving of the sections library to disk. The following tables list the
properties and methods of the SectionsLibrary object.
Page 109
Chapter 8 Sections Library
Properties
The three methods FullName, Name, and Path describe the location of the sections
library file. The Path property contains the disk path of the file, the Name property
returns the name of the file while the FullName property returns the name of the file
including the path.
The Modified property is used to determine if the library has been changed and needs to
be saved. This property returns a value of true if the sections library has been altered. It
will most commonly be used conjunction with the methods to open and save the library.
The SectionGroups and Materials properties return collections containing the groups
and material stored within the sections library.
Methods
A new library is loaded into Multiframe using the Open method of the SectionsLibrary
object. The following script demonstrates how to open a new sections library using
VBA and Microsoft Excel. In this example the user is prompted to select the library to
be opened via the File Open dialog.
Dim Filename As String 'name of file to open
Dim Filter As String ‘filter for section library files
End If
End With
The sections library may be saved to file using the Save or SaveAs methods. The
Save method saves the library using it’s current file name and path. The SaveAs
method saves the library as a new file. It would be implemented within a script in a
similar was to the examples shown above for opening a library.
Page 110
Chapter 8 Sections Library
The simplest way to access a section within the sections library is using the GetSection
method. This method provides a means of accessing a particular section without having
to navigate the object hierarchy of the sections library. This method can take up to two
parameters that identify the section and returns the Section object corresponding to the
specified section. The first parameter is generally used to identify the group containing
the section. This can be any variant value used to represent a group such as its number,
name or a SectionGroup object. The second parameter is also a variant value and is used
to identify the section. This may be the index of the section within the group, or it’s
name. The GetSection object may also be used with only a single parameter that
specifies the name of the section. In this case, the entire library will be searched to find a
section with a matching name. The many ways in which the GetSection method may be
used are demonstrated in the following code.
Dim mySection as Multiframe.Section
Dim myGroup as Multiframe.SectionGroup
SectionGroup Object
The SectionGroup object encapsulates a group of sections within the sections library.
These sections are stored within the SectionGroup object as a collection of Section
objects. The properties and methods of the SectionGroup object are listed below.
Page 111
Chapter 8 Sections Library
The InputBox function is a VBA function that displays a dialog in which the user is
prompted to enter a text string.
Properties
The name of the group is interfaced via the Name property of the SectionGroup object.
This property is a string that can be up to 31 characters long. To be consistent with the
other Multiframe objects, the name of the group can also be referenced via the hidden
Label property of the SectionGroup object
The Locked property of a SectionGroup is a Boolean value that is set equal to true if
the group is locked and cannot be modified. This also excludes the modification of any
sections contained within the group.
The sections contained within this group are stored within a collection of Section
objects that is accessed via the Sections property of the SectionGroup object. A useful
property of the SectionGroup object is the SectionsNames property. It returns a list
of names of all the sections contained within the group. The names of the sections are
listed in the order in which they appear within the Sections collection contained within
this group. This method can be used to rapidly provide data to a user form or dialog
containing a list of groups from which the user may choose a section.
The SectionsLibrary and Application objects return the parent objects containing this
SectionGroup object.
Page 112
Chapter 8 Sections Library
Sections Object
The Section object stores the data describing a single section within the sections library.
Most of the properties in this object provide access to all of the geometric properties of
the section that are used for analysis and design. Other properties store the sections
name, its shape and details of it symmetry. The properties of the Section object are
listed in the four tables shown below. The first two tables lists all the properties and
method of the Section object that do not directly access the section properties of the
section. The next table lists properties of the Section object that reference the
dimensions of the section while the final table lists the properties for accessing the
derived section properties of the section such as it’s area and moments of area.
Page 113
Chapter 8 Sections Library
Page 114
Chapter 8 Sections Library
Note that the naming convention for the elastic and plastic section modulii do not follow
the naming convention generally adopted in the United States. In the Multiframe
automation interface, the elastic plastic modulus is denoted using a Z while the plastic
section modulus is denoted using an S.
Page 115
Chapter 8 Sections Library
Properties
The name of the section is referenced via the Name property of the Section object.
This property is a string that can be up to 31 characters long. The name of the section
can also be accessed via the hidden Label property of the SectionGroup object
The Shape property is an enumerated value of type mfSectionShape that identifies the
shape of the section. This enumerated type has values corresponding to each of the
standard section shapes supported within Multiframe.
The SymmetricXX and SymmetricYY are Boolean properties of the Section object and
return a value of true if the section is symmetric about the x or y axes respectively.
These properties are derived from the shape of the section but if the shape is non-
standard, the symmetry of the section will be determined from its section properties.
The SectionGroup, SectionsLibrary and Application objects return the parent objects
containing the Section object.
Methods
The section properties of the section can also be accessed via the GetProperty method
of the Section object. This method accepts a single parameter of type mfSectionProp
that identifies the property of the section to be returned. The values of the properties
may also be set using the SetProperty method. This method takes two parameters; the
first identifies that section property and the second the new value of the section property.
Page 116
Chapter 8 Sections Library
The Compute method of the Section object calculates the section properties of the
section from its shape and dimensions. This method will generally be called after adding
a new section to the sections library. The example shown above for adding sections to
the Frame group would generally be extended to compute the properties of the section as
listed below.
Dim section as Multiframe.Section
Dim mySectList as Multiframe.SectionList
Dim Names(1 to 5) as string
Dim Widths(1 to 5) as double
Dim I as long
Locked Groups
A sections group may be set as locked in which case the properties of the
group and the sections it contains cannot be modified. This prevents the
user from inadvertently modifying data within groups containing standard
sections.
Page 117
Chapter 9 Preferences and Units
Sign Conventions
The sign convention for axial forces used within Multiframe application is identified by
the TensionPositive property of the Preferences object. When this property is set
true, all axial forces within the Multiframe user interface, and the automation interface,
will be displayed such that tensile forces have positive values and compressive forces
negative values.
Units
The Multiframe user interface allows the user to customise the units used to display and
input quantities into the application. The same units settings also govern the input and
output of values from the automation interface. The Preferences object provides
several methods and properties for working with units. The unit set used within
Multiframe to display quantities is specified by the UnitSet property. This is an
enumerated value of type mfUnitSets that has values corresponding to one of predefined
sets of units (Australian, Japanese, American, etc.). To use the American unit set, the
following line would be added to a script
mfApp.Preferences.UnitSet = mfUnitsetAmerican
The individual units within the unit set selected within the application may be
determined using the GetUnit method. This method is very useful in constructing VBA
forms or fields for inputting information as it provides a means of communicating the
current units of measure. The GetUnit method returns a string containing the
abbreviated name of the unit as specified by the single parameter of the method that
identifies the type of unit (length, force, angle, etc). The individual units of measure are
identified using an enumerated value of type mfUnitType. As an example, a string
containing the name of the current units of length would be obtained as follows
Dim s As String
s = mfApp.Preferences.GetUnit (Multiframe.mfUnitLength)
Page 119
Chapter 9 Preferences and Units
The units used within the current unit set can be changed using the SetUnit method of
the Preferences object. This method takes two parameters; the first is an enumerated
value of type mfUnitType that identifies the units to be changed. The second parameter
is a string that specifies the name of the units to be used. For example, to change the
units of length to feet would require the following line of code
mfApp.Preferences.SetUnits(mfUnitLength,”ft”)
Allowable values of the unit names for each of the unit types are those listed in
Multiframes Units dialog. A summary of the different units of measurement that can be
set within Multiframe is listed in the table below.
Page 120
Chapter 10 Collections
Collections
A collection within the Multiframe object model is a container for storing an ordered
group of objects. It is essentially the equivalent of an array within VBA but its
implementation has been encapsulated within an object. As such, it provides some
methods and properties for accessing the items within the collection. The contents of a
collection is not arbitrary, in fact its contents correspond directly to the components of a
structural model. As such, adding an item to a collection adds a corresponding
component the structure. For example, all the elements representing a frame are
contained within an Elements collection object stored within the Frame object. Adding
a new element to the frame is performed by adding a new element to the Elements
collection.
All collection objects have a number of common properties and methods for
manipulating their content. These are summarised in the tables below.
Collection Properties
Collection objects have a single property, Count, which returns the number of objects
contained within the collections.
Dim nEls as long
’Tell user
MsgBox “Frame contains " & nEls & “ elements.”
Page 121
Chapter 10 Collections
Collection Methods
Each collection object has a method for adding new items to the frame. The name of this
method will vary from collection to collection but it will always begin with the word
Add. For example, a new spring is added to the frame using the AddSpring method of
the Springs collection. Most collections will also feature a method for adding multiple
objects to the frame. These methods are named as the plural of the method for adding a
single object to the frame. Continuing the previous example, a number of springs can be
added to a frame using the AddSprings method of the Springs collection. The add
methods associated with each collection are described earlier in this manual in the
section associated with the objects contained by the collection.
.Item(1).Orientation = 45
End With
The Find method of a collection object is used to search the items in the collection for
objects with properties matching a specified criterion. This method returns a list object
containing the items meeting the criteria. This last section of this chapter describes this
method in detail.
Lists
A drawback of using automation is that calls between the applications are relatively
slow. To ensure that your scripts run quickly it is important to reduce the number of
calls between the applications. In Multiframe we have introduced list objects that
provide a means of accessing and manipulating the properties a number of objects in a
single statement. List objects are similar to collections in that they store a number of
objects in an array. However, list objects can store an arbitrary group of objects while
collections store all the instances of a particular type of object. For example, the Nodes
collection provides a reference to all the nodes in a frame. An arbitrary subset of these
nodes can be stored using the NodeList object.
Each collection of objects in Multiframe has a corresponding list object that may be used
to store an arbitrary list of objects. All list objects have a number of common properties
and methods for manipulating their content. These are summarised in the tables below.
Page 122
Chapter 10 Collections
The behaviour and use of these properties is described in detail in the following sections.
Each list object also has a number of properties that it inherits from the objects it
contains. These properties can be used to access the properties of each of the objects
contained within the list. For example, the NodeList object has Label, x, y, z and
Pinned properties that are used to access the properties of all the node objects contained
within the list. In general, list objects have most of the properties of the objects
contained within the list. The properties of individual list objects used in the Multiframe
object model are not described in detail within this manual. Instead, a general
description of how these properties are derived from the properties of the objects
contained in the list is provided in this chapter.
Declaring Lists
List objects differ from the other objects and collections in Multiframe object model, as
they do not have a direct representation within the Multiframe user interface. When
declaring a list object, a new instance must be created by declaring the object using the
New keyword. For example
Dim myList as New Multiframe.ElementList
Dim myOtherList as New Multiframe.NodeList
Properties
The list objects have just two properties that are common to all list objects. The Count
property of a list object returns the number of items in the list while the Unique property
determines if each item in the list must be unique. That is to say that any object can only
appear in the list once. If a list is set to contain only unique items then adding any items
to a list that are already in the list will have no effect and no error message will be
returned. Furthermore, if a list is set unique then all duplicate items will be removed
from this list. By default all items in a list are not required to be unique. A useful
application of a unique list is illustrated below in which the number of sections used in
the frame is computed.
Dim myElList As New Multiframe.ElementList
Dim mySectList As New Multiframe.SectionList
’Nullify objects
Set myElList = Nothing
Set mySectList = Nothing
Page 123
Chapter 10 Collections
In addition to the properties common to all lists, each list object has many of the same
properties as the objects it contains. However, these properties do not return a single
value but a variant containing an array of values, each array entry corresponding to the
value of the property for each item within the list. For example, the NodeList object has
x, y and z properties describing the location of the nodes in the list. Each property
returns an array of real number values representing the position of each node in the list.
The properties of a list may also be used to set the values of properties of objects
referenced by the list. In this case the property of the list can be set equal to a single
value, in which case the same value will be applied to all items within the list, or the
property can be set equal to an array of values that specifies a separate value for each
item in the list. In the following example, the x-coordinate of all nodes in a frame are
scales by a factor of 2.5. The script firstly extracts all the x-coordinates of each node
into an array. The values in this array are then multiplied by a factor of 2.5. This array
is then used to set the x-coordinates of the nodes in the list. The final line of the script
then sets the z-coordinate of all the nodes in the list to zero.
Dim myNodeList as New Multiframe.NodeList
Dim myVar as Variant
Methods
An item is added to a list using the Add method. By adding an item to a list we are
adding a reference to that item to the list. This should not be confused with the Add
methods of the collection objects that create new items within the frame. To
complement this method, the Remove method is used to remove items from the list.
These methods take one or more variant parameters that specify the items to be added to
the list. List of nodes, elements and other objects modelling the frame require only a
single parameter that identifies the items to be added or removed from the list. As it is a
variant value any value representing a single object or a number of objects contained by
the list would be valid. For example, the contents of an ElementList object could be
specified in any of the following ways
Page 124
Chapter 10 Collections
’Nullify objects
Set myElList = nothing
Set myOtherList = nothing
This example uses the Clear method of the list object. This method, which is common to
all list objects, removes all items from the list. List of items such as loads or sections
allow for two parameters to be used as part of the Add method in order to specify the
items to be added to the list. In these cases, the objects to be referenced by the list
cannot be referenced by only their index or number and require a second parameter to
specify a load case, section group or result type. The following code demonstrates how
to create list of element loads.
With mfApp.Frame
’Add items to lists using loads index within a load case
myList.Add 6,2 ‘Add load 6 from load case 2
myList.Add “1-5”,2 ‘Add loads 1 to 5 from case 2
myList.Add “6-10”,”DL + LL” ‘Add loads from “DL+LL” case
myList.Add “1,5,9”,.LoadCases(1) ’Add loads from 1st case
End With
All of the items in a list can be deleted from a frame using the Delete method of a list
object. Do not confuse this method with the Remove method that only removes a
reference to an object from the list. The following code uses list objects to delete all the
loads applied to a group of elements.
Dim myElList as New Multiframe.ElementList
Dim myLoadList as New Multiframe.ElementLoadList
Page 125
Chapter 10 Collections
A slight more sophisticated script is shown below in which all the elements at a
particular height are obtained by firstly searching all the elements within a frame to find
those with the first end position at the specified height. The results from this query,
stored as an ElementList object, are then searched to find all elements that have their
second end positioned at the correct height. All the elements in the resulting list of
elements are then labelled as “Floor 1”.
Dim myElList As New Multiframe.ElementList
’myEllist.Members.Label = “Floor 1”
Find using results
Dim myList As New Multiframe.MemberResultList
’myEllist.Members.Label = “Floor 1”
Page 126
Chapter 11 User Interface
This chapter describes the objects used to interact with Multiframes user interface. The
small number of properties and methods of objects used for modelling the frame that
provide interaction with the user interface are described elsewhere in this manual.
Selection Object
The automation interface can interact with the selection in any of Multiframes windows.
The selection is stored within a Selection object that encapsulates lists of the selected
items. For instance, the nodes contained within a selection are stored in a NodeList
object that is returned by the Nodes property of the Selection object. Similarly the
Elements property of the Selection object returns an ElementList containing each of
the selected elements.
The properties and methods of the Selection object are summarised in the tables below.
Using Selections
The implementation of selections within the automation interface is significantly
different to the other objects as a Selection object does not correspond directly to a
selection within Multiframe and, as such, is not represented within object hierarchy. The
advantage of this implementation is that many selections can be created, stored and
manipulated without any restrictions imposed by the Multiframe application. However,
the disadvantage is that a selection in a window is not automatically updated as items are
added or removed from lists within a Selection object.
To use a selection object, a new instance must first be created by declaring the selection
using the New keyword.
Dim mySelection as New Multiframe.Selection
Page 127
Chapter 11 User Interface
The current selection in one of Multiframes windows can be obtained using the
Selection property of the Frame object. This property has a single parameter that
identifies the window containing the desired selection. The Selection property is read-
only and so a selection can only be set using the SetSelection method of the Frame
object. The methods takes up to three parameters that specify the selection, a window in
which the selection is to be set, and an optional parameter specifying if the current
selection in the window is to be extended. By default the SetSelection will replace any
existing selection with the new selection. As an example of using the Selection object,
the following code demonstrates how to set the selection in the load window to be the
same as the selection in the Frame window
Dim mySelection as New Multiframe.Selection
Properties
The Elements property of the Selection object returns an ElementList object
containing references to each of the elements in the selection. This property can be set
equal to any variant value representing either a single node or a list of nodes. The
following script illustrates many of the ways in which this property can be accessed.
Dim mySelection as New Multiframe.Selection
Dim myEllist as New Multiframe.ElementList
’Set selection
mySelection.Elements = 1
mySelection.Elements = myEllist
mySelection.Elements = mfApp.Frame.Elements
mySelection.Elements = “1,3,5,7”
The Members and Nodes properties of the Selection object returns list objects that
contain references to each of the selected nodes and members. These properties behave
in the same way as the Element property and can be set equal to any variant values
representing a single or a group of nodes or members. A further example demonstrating
the use of the Selection object and the Nodes properties is listed below.
Page 128
Chapter 11 User Interface
Methods
The Clear method of the Selection object removes all items from the selection. The
IsEmpty method returns true if the selection empty and contains no selected items.
Page 129
Chapter 12 Examples
Chapter 12 Examples
This chapter presents a number of examples demonstrating how Multiframe can interact
with other applications via VBA scripting. Many of the sample are designed to
demonstrate different means of manipulating the data. The simplest and slowest
techniques involve accessing the individual objects. However, these are the simplest to
understand and are a good starting point when learning the Multiframe Object Model.
More advance techniques that employ Multiframes list objects demonstrate the dramatic
improvement in speed that can be obtained by accessing the data in Multiframe for
number of objects at a time.
The Excel workbook contains worksheets representing each of the tables within
Multiframes Data Window. Each of these worksheets contains a number of macros that
import the data from Multiframe and present the information in the spreadsheet. As
these macros are very similar for each table, this example will concentrate on the macros
for importing the Joints table into Excel. The Excel representation of this table is shown
in the diagram below.
This worksheet contains two buttons for importing the data from Multiframe. These call
different scripts that demonstrate two techniques for importing the data. The first and
simplest of these scripts accesses the properties of each node in turn. The execution of
this code will be very slow as six (6) calls between the two applications are required for
each node in the frame. The second script uses the list objects in Multiframe to extract
all the nodal data from Multiframe in a total of only six (6) calls across the automation
interface. For small frames, the difference in speed between the two subroutines is
small, in the order of a factor of two. For large frames, the difference in speed will be
dramatic and the slower of the subroutines will take a long time to execute. Each of
these scripts is described in more detail later in this section.
Page 131
Chapter 12 Examples
The Joints worksheet contains 5 subroutines; the first two subroutines are command
handlers for the two buttons that appear in that worksheet. The next subroutine stored
with the Joints worksheet is the SetupUnits subroutine. This subroutine is responsible
for setting the unit names displayed at the top of the table in row 5 of the spreadsheet.
'Set units in title of table
Private Sub SetupUnits(mfApp As Multiframe.Application)
Dim s As String
End Sub
In this subroutine, the names of the length and angle units are obtained by calling the
GetUnit method of the Multiframe Preferences object. These values are used to set the
unit names in row 5 of the worksheet. The offset method of the Range object is used to
identify a cell, relative to the JointData range, into which each value is inserted. The
JointData range is a named range in the excel spreadsheet which contains the single cell
A5.
Page 132
Chapter 12 Examples
ErrorHandler:
If (Err <> 0) Then
MsgBox Err.Description
End If
End Sub
The first executable line of this subroutine defines the mechanism for reacting to any
errors that may arise during the execution of the script. The next statements call
subroutines that firstly clear the table of any existing data and then update the names of
the units in the heading rows of the table using the SetupUnits subroutine described
above. The ClearTable subroutine, which is defined in Module1 of the VBA project,
takes a single parameter specifying a named range within the worksheet. It uses this
range to construct a region to be erased by firstly selecting the column beneath this range
down to the first empty cell. This selection is used to construct a range that contains the
first 20 columns of the worksheet which is then is cleared of it content.
Page 133
Chapter 12 Examples
End Sub
The next group of lines in the script performs the exchange of data between Multiframe
and Excel. Rather than use a more traditional For/Next loop, a For Each loop provides
the mechanism to loop over all the nodes in the frame.
For Each Node In mfApp.Frame.nodes
Next
This type of loop has been used as it simplifies the syntax of the code inside the loop and
does no require a explicit call to reference the Node object. Inside this loop, the
properties of each node are extracted and placed in the appropriate cell of the worksheet.
This is performed by accessing cells relative to the range named JointData using the
offset property of Excels Range object.
The next small block of code in the script formats the data in the table. This is done by
specifying a value for the NumberFormat property of a Range object that contains all
the data in the 3rd through to the 9th column of the table.
'Set format of cells
With Range("JointData")
Range(.offset(1, 2), .offset(i, 8)).NumberFormat = gFormat
End With
The constant gFormat, defined in Module1 of the VBA project, specifies a real number
format to be used when displaying the tables in this workbook.
'Global real number format
Public Const gFormat As String = "##0.000"
By using a global constant, the format of real number can easily be changed throughout
the entire workbook with only a change to a single line of code.
A much faster subroutine for importing the data from Multiframe is listed below. This
subroutine utilised Multiframes list objects to significantly reduce the number of call
between Excel and Multiframe and this provides a significant reduction in the time it
takes to fill the table. The speed of the subroutine has also been improved by disabling
the refresh of excel while the data is been inserted and by using Excels Find and Replace
features to rapidly synthesis data into a presentable form.
Page 134
Chapter 12 Examples
End With
ErrorHandler:
If (Err <> 0) Then
MsgBox Err.Description
End If
End Sub
Page 135
Chapter 12 Examples
Much of the code at the start and end of this subroutine is the same as described above
for the GetNodalData_Slow subroutine. It is only the part of the code that performs
that actual exchange of data between the two applications that is significantly different. It
is also much more complicated to understand due to the list objects and the use of variant
data types.
The subroutine works by firstly defining the variable TableData that is an array of
variants. Each variant in this array corresponds to a column in the table. The script then
forms a list of elements containing all the nodes in the frame
myNodeList.Add mfApp.Frame.nodes
This list is used to extract the properties of each node as an array of values. This data is
inserted into an element of the array TableData so that the TableData becomes
essentially a two dimensional array containing all the data to be inserted into the
worksheet.
TableData(1) = myNodeList.Number
TableData(2) = myNodeList.label
TableData(3) = myNodeList.x
TableData(4) = myNodeList.y
TableData(5) = myNodeList.z
TableData(6) = myNodeList.pinned
TableData(7) = myNodeList.OrientX
TableData(8) = myNodeList.OrientY
TableData(9) = myNodeList.OrientZ
The data is inserted into the worksheet by setting the Value property of a Range object
representing the entire table equal to TableData. As Excel inserts an array in a row wise
manner, it is necessary to first transform the data in TableData by transposing the rows
and columns.
'Insert raw data into table
With Range(.offset(1, 0), .offset(nRows, 8))
.Value = WorksheetFunction.Transpose(TableData)
End With
As the data flagging the nodes as pinned is inserted directly into the worksheet as a
boolean value it is necessary to transform the boolean values of TRUE and FALSE into
the more meaningful values of “Pinned” and “Rigid”. To perform this, the Replace
method of the Range object is used to firstly set all occurrences of the word FALSE in
the 6th column equal to “Rigid”. Similarly all the values of TRUE are replaced with the
value “Pinned”.
'Set joint type as "Pinned" or "Rigid"
Call
Range(.offset(1,5),.offset(nRows,5)).Replace("FALSE","Rigid")
Call
Range(.offset(1,5),.offset(nRows,5)).Replace("TRUE","Pinned")
Each of the other worksheets in the Excel workbook contains similar subroutines for
importing data from Multiframe and reproducing the other tables in Multiframes Data
Window. The structure of the subroutines is similar to those described above. As this
worksheet demonstrates how to access most of the data describing a frame it is a good
starting point when learning how to access information about a frame via the automation
interface.
Handling Errors
When writing any program it is a good practice to elegantly handle any
errors that may arise during the execution of the code. When writing scripts
in VBA the On Error command is used to specify the action to be taken
when an error occurs.
Page 136
Chapter 12 Examples
The structure of the subroutines in this workbook is the same as those used in the
previous example. For a description of the VBA scripts you should refer to that
example.
The report is generated as a series of tables describing the elements of the structure, the
loading and, if available, the results. Each table in the report is generated by a separate
subroutine. These have been grouped into 4 modules within the VBA project. The
FrameTables module contains the subroutines for generating the tables describing the
structure, the LoadTables module contains those for reporting loads and the ResultTable
module encapsulates all the subroutines for outputting the results. The 4th module,
named Utilities, contains some utility subroutines used to create tables and format the
report.
The MFReport.doc document contains two buttons. The Generate Report button is used
to run the Generate Report
The GenerateReport subroutine is the main routine for compiling the report. It calls all
the subroutines for generating the individual tables within the report and is responsible
for creating the titles to the various sections of the report. This subroutine is also used to
set the values of some global variables that store the names of some commonly used
units, and for setting the contents of the headers and footers in the report.
Page 137
Chapter 12 Examples
All of the subroutines for generating a table within the report have the same structure and
use the same techniques for extracting the data from Multiframe and creating a table
containing that information. The InsertMbrGeomTable() subroutine, which is listed
below, is a typical example of these subroutines. This subroutine inserts a table
containing the properties of elements within the frame. It is written to minimise the
number of calls between Word and Multiframe by using the ElementList object. By
adding all the elements in the frame to an ElementList, the value of a single element
property can be obtained for each element in the frame in a single call to Multiframe.
These values are stored in a variant variable that contains an array of values, each value
corresponding to an element within the frame. The subroutine begins by obtaining all of
the data to be presented in the table and storing this data as in arrays declared as variants.
Page 138
Chapter 12 Examples
Sub InsertMbrGeomTable()
nEls = mfApp.Frame.Elements.Count
If (nEls > 0) Then
Else
Call EmptyTableMessage("Members")
End If
End Sub
Rather than insert a table and set the contents of each cell in the table, the data is inserted
into the document as tab delimited text. This delimited text is then converted into a table.
Page 139
Chapter 12 Examples
With ActiveDocument.Content
'Create single paragraph to seperate table from title
.InsertParagraphAfter
End With
With ActiveDocument.Content.Paragraphs.Last.Range
'Delete vertical tab on last line of text
.Characters.Last.Previous.Delete
End Sub
Page 140
Appendix A Object Model Summary
Objects
The objects defined with the Multiframe object model are summarised in the following
table. It lists each object and its associated collection and list objects.
Page 141
Appendix A Object Model Summary
TimeHistoryResults - -
TimeHistorySettings - -
Enumerated Types
All the enumerated type defined with the Multiframe Object Model and their values are
summarised below.
mfActionType
mfActionPx = 1 mfActionThetaZ = 24
mfActionVy = 2 mfActionTension = 25
mfActionVz = 3 mfActionCompression = 26
mfActionTx = 4 mfActionTensileStress = 27
mfActionMy = 5 mfActionCompressiveStress = 28
mfActionMz = 6 mfActionTensileMyStress = 29
mfActionPxStress = 7 mfActionCompressiveMyStress
mfActionVyStress = 8 = 30
mfActionVzStress = 9 mfActionTensileMzStress = 31
mfActionTxStress = 10 mfActionCompressiveMzStress
mfActionMyLeftStress = 11 = 32
mfActionMyRightStress = 12 mfActionBiaxialTensileStress =
mfActionMzTopStress = 13 33
mfActionMzBottomStress = 14 mfActionBiaxialCompressiveStre
mfActionPxMyLeftStress = 15 ss=34
mfActionPxMyRightStress = 16 mfActionMxGlobal = 35
mfActionPxMzTopStress = 17 mfActionMyGlobal = 36
mfActionPxMzBottomStress = 18 mfActionMzGlobal = 37
mfActionU = 19 mfActionWx = 38
mfActionV = 20 mfActionWy = 39
mfActionW = 21 mfActionWz = 40
mfActionThetaX = 22
mfActionThetaY = 23
mfAnalysisType
mfAnalysisStatic = 1 mfAnalysisTimeHistory = 3
mfAnalysisModal = 2 mfAnalysisStaticNonlinear = 4
mfConvergenceNorms
mfConvergenceForce = 1 mfConvergenceBoth = 3
mfConvergenceDisplacememt =
2
mfDOF
mfDOFx = 1 mfDOFthetax = 4
mfDOFy = 2 mfDOFthetay = 5
mfDOFz = 3 mfDOFthetaz = 6
mfElementType
Page 142
Appendix A Object Model Summary
mfEltypeStandard = 1 mfEltypeCompressionOnly = 3
mfEltypeTensionOnly = 2
mfLoadCaseType
mflcStatic = 1 mflcSelfWeight = 3
mflcCombined = 2
mfLoadType
mfLoadUnknown = 0 mfLoadLiquidPressure = 7
mfLoadPermanent = 1 mfLoadEarthPressure = 8
mfLoadImposed = 2 mfLoadGroundWater = 9
mfLoadWind = 3 mfLoadMovement = 10
mfLoadSeismic = 4 mfLoadCombined = 11
mfLoadSnow = 5 mfLoadOther = 12
mfLoadPonding = 6
mfLoadShape
mfLoadshapePoint = 1 mfLoadshapeTriangular = 4
mfLoadshapeUniform = 2 mfLoadshapeTriLinear = 5
mfLoadshapeLinear = 3
mfModalScaling
mfModalScalingUnitDisp = 1 mfModalScalingUnitMass = 2
mfModalSolver
mfModalSolverSSI = 1 mfModalSolverJacobi = 2
mfReportLevels
mfReportingNone = 1 mfReportingDetailed = 3
mfReportingBrief = 2 mfReportingFull = 4
mfRestraintType
mfRestraintUnknown = 0 mfRestraintPinnedzRoller = 5
mfRestraintPinned = 1 mfRestraintRigidxRoller = 6
mfRestraintFixed = 2 mfRestraintRigidyRoller = 7
mfRestraintPinnedxRoller = 3 mfRestraintRigidzRoller = 8
mfRestraintPinnedyRoller = 4 mfRestraintRotational = 9
mfSectionProp
mfSectionPropMass = 1 mfSectionPropE = 6
mfSectionPropArea = 2 mfSectionPropG = 7
mfSectionPropIx = 3 mfSectionPropD = 8
mfSectionPropIy = 4 mfSectionPropB = 9
mfSectionPropJ = 5 mfSectionPropTf = 10
Page 143
Appendix A Object Model Summary
mfSectionPropTw = 11 mfSectionPropZvr = 40
mfSectionPropFy = 12 mfSectionPropXs = 41
mfSectionPropFu = 13 mfSectionPropYs = 42
mfSectionPropZxt = 14 mfSectionPropPerimeter = 43
mfSectionPropZxb = 15 mfSectionPropTanTheta = 44
mfSectionPropZyl = 16 mfSectionPropSpacing = 45
mfSectionPropZyr = 17 mfSectionPropR1 = 46
mfSectionPropRx = 18 mfSectionPropR2 = 47
mfSectionPropRy = 19 mfSectionPropIxy = 48
mfSectionPropSx = 20 mfSectionPropSu = 49
mfSectionPropSy = 21 mfSectionPropSv = 50
mfSectionPropIw = 22 mfSectionPropTaper = 51
mfSectionPropRz = 23 mfSectionPropUser1= 52
mfSectionPropAsx = 24 mfSectionPropUser2= 53
mfSectionPropAsy = 25 mfSectionPropUser3= 54
mfSectionPropD1 = 26 mfSectionPropUser4= 55
mfSectionPropD2 = 27 mfSectionPropUser5= 56
mfSectionPropB1 = 28 mfSectionPropXp = 57
mfSectionPropB2 = 29 mfSectionPropYp = 58
mfSectionPropXc = 30 mfSectionPropT1= 59
mfSectionPropYc = 31 mfSectionPropT2= 60
mfSectionPropTheta = 32 mfSectionPropR0= 61
mfSectionPropIu = 33 mfSectionPropH = 62
mfSectionPropIv = 34 mfSectionPropK1= 63
mfSectionPropRu = 35 mfSectionPropK2= 64
mfSectionPropRv = 36 mfSectionPropQf = 65
mfSectionPropZut = 37 mfSectionPropQw = 66
mfSectionPropZub = 38 mfSectionPropC = 67
mfSectionPropZvl = 39
mfSectionShape
mfSectionUnknown = 0 mfSectionCircularBar = 9
mfSectionI = 1 mfSectionSquareBar = 10
mfSectionChannel = 2 mfSectionC = 11
mfSectionEqualAngle = 3 mfSectionZ = 12
mfSectionUnequalAngle = 4 mfSectionUnsymI = 13
mfSectionTee = 5 mfSectionEqualAnglePA = 14
mfSectionRHS = 6 mfSectionUnequalAnglePA = 15
mfSectionSHS = 7 mfSectionDoubleAngle = 16
mfSectionTube = 8
mfSign
mfSignPositive = 1 mfSignAbsolute = 3
mfSignNegative = 2
mfSpringType
mfSpringStandard = 1 mfSpringCompressionOnly = 3
mfSpringTensionOnly = 2
Page 144
Appendix A Object Model Summary
mfUnitSets
mfUnitsetAmerican = 1 mfUnitsetCanadian = 4
mfUnitsetAustralian = 2 mfUnitsetEuropean = 5
mfUnitsetBritish = 3 mfUnitsetJapanese = 6
mfUnitType
mfUnitNone = 0 mfUnitInertia = 12
mfUnitLength = 1 mfUnitDensity = 13
mfUnitAngle = 2 mfUnitModulus = 14
mfUnitDisplacement = 3 mfUnitSpring = 15
mfUnitAngularDisplacement = 4 mfUnitTorsionSpring = 16
mfUnitForce = 5 mfUnitTemperature = 17
mfUnitMoment = 6 mfUnitTemperatureCoeff = 18
mfUnitUdl = 7 mfUnitRotationalMass = 19
mfUnitStress = 8 mfUnitVelocity = 20
mfUnitMass = 9 mfUnitAcceleration = 21
mfUnitMassPerLength = 10 mfUnitWarping = 22
mfUnitArea = 11
mfWindow
mfWinActive = 0 mfWinResults = 4
mfWinFrame = 1 mfWinPlot = 5
mfWinData = 2 mfWinCalcsheet = 6
mfWinLoad = 3 mfWinReport = 7
Page 145
Index
Index
ModalResults Object, 98
A
ModalSettings Object, 92
Analysis, 89 Multiframe Object Model, 15
Linear Static, 90
N
Modal, 92
Non-linear Static, 90 NodalResult Object, 99
Time History, 93 Node Object, 38
Analysis Object, 89 NodeLinkGroup Object, 57
Application Object, 17 NodeLoad Object, 78
NodeMass Object, 60
C
NodePreDisp Object, 80
Collections, 15 NonlinearResults Object, 97
E NonlinearSettings Object, 90
Early Binding, 12 O
Element Object, 43 Object Browser, 13
ElementLoad Object, 81 Objects, 15
ElementResult Object, 101 Analysis, 89
F Element, 43
ElementLoad, 81
Frame Object, 18, 35 ElementResult, 101
G Frame, 35
Groups, 64
Groups Object, 64 GroupSets, 63
GroupSets Object, 63 LinearResults, 97
L LinearSettings, 90
LoadCase, 75
Late Binding, 12 MemberResult, 107
LinearResults Object, 97 Members, 67
LinearSettings Object, 90 ModalResults, 98
Lists, 15 ModalSettings, 92
Load Cases NodalResult, 99
Combined, 77 Node, 38
Self-Weight, 76 NodeLinkGroup, 57
Static, 76 NodeLoads, 78
LoadCase Object, 75 NodeMass, 60
Loads NodePreDisp, 80
Deleting, 87 NonlinearResults, 97
Element loads, 81 NonlinearSettings, 90
Node Loads, 78 Preferences, 119
Prescribed Displacements, 80 ProjectInfo, 71
Thermal loads, 85 Restraints, 53
M ResultCase, 96
Results, 95
Member Object, 67 SectionGroup, 111
MemberResult Object, 107 Sections, 113
Methods SectionsLibrary, 109
Common, 22 Springs, 55
Delete, 23 ThermalLoad, 85
Item, 23
Page 147
Index
Page 148