Complex Line Numbers in Isometrics

Out of the box, the line number tag, size and spec are called out on isometrics.


One of the most frequent requests we get is to alter that line callout to match our line number. The difficulty lies in the fact that in the isoconfig.xml, when you tell it which fields to place, you can’t mix and match the component properties with the line group properties.  So, for example, setting up a line number like this Size-Service-Number-Spec, seemed impossible (where size and spec are the component properties.

However, thanks to some recent insight from the forums thanks to Bernd Gerstenberger, we have a workable (though complicated) solution.


The key to our scenario is to use a little know feature called calculated properties (PLANTDEFINECALCPROPERTIES).


We still have to work with the limitation of placing component fields separately from line group properties, but by using the Calculated properties option, we can create a new field/fields that includes our line group properties in the order we want.  We do have to workaround a limitation in that calculated properties cannot include the size property (from components).


What is a Calculated property?

Before diving headlong into this, we need to understand what a calculated property is.  A calculated property is a combination of existing properties for a class.  Calculated properties may be defined and edited using the PLANTDEFINECALCPROPERTIES command.


Below is a screenshot of a calculated property called “LineDisplay” that was created on the P3dLineGroup class.



In the Data Manager, the LineDisplay Property looks like this:


The format of the calculated property is important.  Typically, everything should be wrapped in the ToString function.  The double bars “||” is a symbol that indicates concatenation. You use single quotes to wrap text.

So, the value used for the LineDisplay property is this: ToString(NominalSize) || ‘-‘ || ToString(Service) || ‘-‘ || ToString(Number) || ‘-‘ || ToString(NominalSpec)


I’m sure I overuse ToString, but it can’t hurt anything.


So, how does this help?  Bernd’s post above shows how to include any component property in an annotation.  So, now we can create a property similar to LineDisplay on our PipeRunComponents class.  The only difference being that due to limitations in calculated properties, we can’t include the Size property.


So, I created a property called LineSuffix on the PipeRunComponent class as shown below:


In our model, the property looks like this:


Now, we need to map the property so that we can use it in our isoconfig.xml.

Open the iso.atr, in the style you want to modify, and add a row that  maps the PipeRunComponent.LineSuffix property.


Now, in the isoconfig.xml, navigate to Themes > Theme (default) > Annotations > AnnotationSchemes > LineNumberScheme.


The attributes we are interested in are the Format, ComponentFormat, and ComponentFields.

In ComponentFields, we indicate that we want to make two properties available (Size and LineSuffix).

In ComponentFormat, we indicate that the format will that the first item (Size) and separate it from the second item (LineSuffix) with a dash.

By default, the Format property puts the LineFormat items first (think Line Group properties), so we use {1} which will only include the ComponentFormat properties. Save that and generate an iso.


Magically, we have the physical size called out with the line number format that matches the LineDisplay property.