OPM Formula to catch Name to cell name

Hi Gents

I am looking for a method in OPM, when we placed a support location, is possible to catch the support number of the support location to the cell name? e.g. in element properties, 

Cell Name = Name as shown the illustrated fig below, can you give some tips how can I make it? I know there maybe some function in class editor, it maybe can add some formula/expression.

I want the parameter "Cell Name" got the name as in OPM support location attribute automatically.

 3107.Empty.dgn

Parents Reply
  • You need to do something like below.

    ScanCriteria* pScanCriteria = mdlScanCriteria_create();

    mdlScanCriteria_addSingleElementTypeTest (pScanCriteria, CELL_HEADER_ELM);
    mdlScanCriteria_setReturnType (pScanCriteria, MSSCANCRIT_RETURN_FILEPOS, FALSE, TRUE);
    mdlScanCriteria_setRangeTest (pScanCriteria, NULL); //no range test
    mdlScanCriteria_setModel (pScanCriteria, ACTIVEMODEL);
    /* loop through all Titel cell elements in file */
    do
    {

    //once you get a cell name here..you need to use EC Framework APIs to extract the EC data and get the Name of the element.

    and then use MDL APIs for changing the cell name Property.

    }

    Answer Verified By: You Quanwu 

Children