Use the following formulas to count the number of closed contours in a drawing.
Formula pattern
for |
use |
COUNTING CLOSED CONTOURS IN A PARTICULAR STYLE |
$ONEUPN.HOLESCOUNT(STYLENAME; YES/NO)$ |
NOTES
Examples
TO COUNT |
USE |
The number of closed contours (holes) in the Cutting style or any of its child styles in the 1up named OneUp1. |
$OneUp1.HolesCount()$ |
The number of closed contours (holes) in the Cutting style in the 1up named OneUp1. |
$OneUp1.HolesCount(Cutting)$ |
The number of closed contours (holes) in the Cutting style outside the closed contours in a drawing named OneUp1 |
$OneUp1.HolesCount(Cutting; false)$ |
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)$ |