How to Get Model Name(filename) from AutoPLANT In Isometrics Using OPIM


Applies ToOpenPlant Isometrics Manager
Product(s):OpenPlant Isometrics Manager
Version(s):SS5, SS6
Environment:Windows 7/8.1/10 (64 bit)
Area:Installation
Subarea:
Original Author:Bentley Product Advantage Group

Overview

How to get the model name (filename) from AutoPlant into the iso using OPIM?

Steps to Accomplish

  1. Open your Isometrics Style configuration folder and select to open node2da.txt file



  2. Add at the end of attributes list add new atribute 00_PipingModel and at the end of this file add the following lines:

    1# If an Access based project is used: (as  example)
    mydsn=Driver={Microsoft Access Driver (*.mdb)};Dbq=C:\ProgramData\Bentley\Plant V8i\Bentley Plant V8i Projects\SAMPLE_METRIC\Projdata\Projdata.mdb;
    OR
    # If a SQL project is used with Windows Authentfication,
    mydsn=Driver={SQL Server};Server=SQL Server name;Database=sql databse name;
    2# If a user id and password option is used add also the following:
    Uid=userid;Pwd=password;
    3# This is the query to get the KEYTAG from the project database using LINENUMBER
    00_keytag = DBQUERY ($(mydsn), select keytag from TAG_REG where tag_no='$(LINENUMBER)')
    4# this makes a drawing attribute compID that gets the most common value of the component attribute GUID
    compId = *(GUID)
    5# This is the query to get the modelname from the project database using compID
    00_PipingModel = DBQUERY ($(mydsn), SELECT D.DOC_NAME FROM DOC_REG AS D INNER JOIN RELATIONSHIPINSTANCE AS R1 ON R1.ID1 = D.DOC_ID WHERE R1.ID2='$(compID)' AND R1.RELATIONSHIPTYPE = 3)



  3. Save and close the file.
  4. Run an iso in the project and in the resulting Iso, go to menu IsoExtractor>Text Node Editor.
  5. Find text node with same number on which you have added new attribute, select it, right mouse click, select Place Text Node.
  6. Place the node on any wanted location and close the Text Node Editor. With this step you will modify text node location in your isometrics seed file and all generated isometrics will be placing this text node on your selected location.


  7. After this step just close OPIM and generate new Isometrics and you will se how file name is placed as annotation on that location where text node was placed.

Comments or Corrections?

Bentley's Product Advantage Group requests that you please confine any comments you have on this Wiki entry to this Comments or Corrections?" section. THANK YOU!