How To Make an Instrument Loop Fetch Information from a Pipe Run


Applies To
Product(s):OpenPlant PID CONNECT Edition
Version(s):10.xx.xx.xxx
Environment:Windows 10/11 (64 bit)
Area:Properties
Subarea:Customizations
Original Author:Álvaro Melgarejo, Bentley Global Technical Support

Overview

Working with OpenPlant PID, the user might have a design where an Instrument Loop is connected to a Pipe Run, and the requirement that one of the Instrument Loop's properties fetches and displays the value of one of the Pipe Run's properties.

In this specific example, a property named Related Pipe Run will be added to the Loop class, it will be inherited by the Instrument Loop class, and the value of that property will be the same as the value of the Name property of the Pipe Run to which the Instrument Loop is connected.

Problem Description

When a Pipe Run and an Instrument Loop are placed on the DGN and connected on some point, there is not an automatic connection established between the two entities. Please notice that there is a connection established between the Pipe Run and the Instruments that are in the Instrument Loop, but not between the Pipe Run and the Instrument Loop itself.

The usual workflow -adding a Calculated ECExpression custom attribute to the property required to fetch the value from the Pipe Run using Class Editor- is not enough, and will always yield the failure value. In order to be successful, an extra step needs to be taken from within OPPID.

This wiki shows the process that needs to be followed in order to achieve the result described above.

Steps To Resolve

  1. Open Class Editor v8i.
  2. Open the schema OpenPlant_PID.01.08.ecschema.xml and supplement it with OpenPlant_PID_Supplemental_Design.01.08.ecschema.xml.
  3. Navigate to the Loop class.
  4. Add a Property named RELATED_PIPERUN.
  5. Add a Calculated ECProperty Specification custom attribute to the newly created property.
  6. Fill the ECExpression field as shown in the picture below.
    ECExpression for copy/pasting - this.GetRelatedInstance("LOOP_HAS_OBJECT:0:PIPING_NETWORK_SEGMENT").NAME

  7. Now open OpenPlant PID CONNECT Edition and place a pipe and a loop as shown in the picture. There is no need make it complicated, a basic pipe and loop suffice as long as the pipe's Name property has a value.
  8. Bring up the File Explorer. Select the loop. Go to the Properties panel and notice the failure value.

    Note: do not click directly on the loop on the graphics window because this will select the instrument in the loop, not the loop itself. Selecting the loop through the File Explorer is necessary.
  9. Go to the Tools tab, and in the Tools ribbon group, select Conformance. Then select Add Relationship.
  10. Select the loop, this time on the graphics window. Select Yes on the prompt. Then click on the Pipe Run.
  11. On the window that pops up, select Loop Has Object.
  12. Now select the loop again through the File Explorer, and notice how the value of the Related Pipe Run property is the same as that of the Pipe Run's Name property.

Please note that if several relationships are established between the same loop and different pipe runs, the value fetched will be that of the pipe run used for the last relationship.