Formulas for extracting overall dimensions in 3D drawings: 3D models and inserted objects

The following two sets of formulas lets you extract the overall dimensions of 3D models and external object inserted into 3D models.

The overall dimensions correspond to the length, width and height of the bounding box that encompasses the 3D model or inserted object. These values are taken from the length, width and height that are displayed in the tabular area of 3D drawings — in the Dimensions column of each phase.

Formulas extracting 3D model dimensions

Formulas extracting the dimensions of inserted objects

Extracting data about placed inserted objects

Formulas for extracting the overall dimensions of 3D models

FORMULA PATTERNS

DRAWING

THE FORMULA TO USE

LENGTH

$Fold3DN.BoundingBoxLength(Phasename; units; Useparts)$

WIDTH

$Fold3DN.BoundingBoxWidth(Phasename; units; Useparts)$

HEIGHT

$Fold3DN.BoundingBoxHeight(Phasename; units; Useparts)$

NOTES:

EXAMPLES

TO CALCULATE

USE

The length, in millimeters, of the bounding box as it appears in the Initial State phase

$Fold3D1.BoundingBoxLength(Initial State; mm; true)$

The width, in millimeters, of the bounding box as it appears in the Production phase

$Fold3D1.BoundingBoxWidth(Production; mm; yes)$

The height, in millimeters, of the bounding box as it appears in the Assembly phase

$Fold3D3.BoundingBoxHeight(Assembly; mm; 1)$

Formulas for extracting the overall dimensions of inserted objects

FORMULA PATTERNS

DRAWING

THE FORMULA TO USE

LENGTH

$Fold3DN.BoundingBoxLength(, units)$

WIDTH

$Fold3DN.BoundingBoxWidth(, units)$

HEIGHT

$Fold3DN.BoundingBoxHeight(, units)$

 

NOTES:

EXAMPLES

TO CALCULATE

USE

The length, in millimeters, of the object inserted in the 3D and linked to the predefined area Fold3D1

$Fold3D1.BoundingBoxLength(, mm)$

The width, in centimeters, of the object inserted in the 3D drawing and linked to the predefined area Fold3D1

$Fold3D1.BoundingBoxWidth(, cm)$

The height, in millimeters, of the object inserted in the 3D drawing and linked to the predefined area Fold3D3

$Fold3D3.BoundingBoxHeight(, mm)$

Note about formulas extracting data about inserted objects

When citing the names of external objects, pay attention to how they are placed into the respective predefined areas.

IN THE DESIGN FRAME

In the following table, the left frames cite the predefined areas. All dimensions-extracting formulas in the right frames refer to the objects placed into the predefined areas.

IMPORTANT: In design frames, Expression means that a formula is correctly entered and will produce an actual result when the design frame is applied in a print drawing.

IN THE PRINT DRAWING

The following pictures shows how external objects are linked to predefined areas as pictured above. While you are setting up the print drawing, you refer the external objects to the predefined area names. In the Print Frame Placement dialog box, you refer the external objects to the predefined areas. When in the dialog box you click Apply, you will see how the formulas are applied and the external objects displayed in the predefined areas.

IMPORTANT: Note the actual extracted overall dimensions of external objects under 3D dimensions.

IMPORTANT: space-separated style names; case-sensitivity; List separator type

SPACE-SEPARATED STYLE NAMES: In a formula, to refer to a style whose name is made up of multiple words separated by spaces, enclose the style name in quotation marks:

$ONEUP1.LENGTH("RILLEN 3PT", m)$

$ONEUP1.LENGTH("RILLEN MIT RILLKÖRPER", m)$

CASE-SENSITIVE INDICATIONS FOR MEASUREMENT UNITS AND FORMATTING: Whenever a formula contains indications for measurement units and formatting, ensure that these are typed in lower case. That is, the formula may be typed in any case you like, but the applied measurement units and formatting indications must be typed in lower case. Consider the following examples, in which the formulas are typed in upper case but the measurement and formatting indications are in lower case:

$Layout1.SheetWidth(mm); n2$

$Layout1.lenght(m)$

LIST SEPARATOR TYPE: Throughout this guide, semicolon — (;) — is used to separate formula attributes. List separators are critical for how the program interprets the attributes within formulas. Your own system, however, may use a default list separator that is different from semicolon — for example, comma (,). In this case, if you simply copy a formula from the help guide and then paste it, error messages will appear and the formula will not calculate.

So while typing a formula, ensure that the list separator used in the formula is identical with the one set for your system. This means that you may need to edit either your system's list separator setting or the formula you are typing. The examples that follow illustrate how you can use formulas with semicolons and colons as list separators:

As presented in the help guide. list separator is semicolon (;)

type it like this if your list separator is comma (,)

$Layout1.Area(m; Plotting); n2$

$Layout1.Area(m, Plotting), n2$

$Layout1.AreaEx(yes; mm); n2$

$Layout1.AreaEx(yes, mm), n2$

$Layout1.SheetHeight(mm); n2$

$Layout1.SheetHeight(mm), n2$

$Fold3D1.BoundingBoxWidth(Production; mm; yes)$

$Fold3D1.BoundingBoxWidth(Production, mm, yes)$