EBDN - Community - Question & Answers

  Saturday, 17 March 2018
  4 Replies
  1.7K Visits
0
Votes
Undo
HI,
I have the following problem:
Under Equipment branch there are two branches of equipment. One of them (let's call it "A";) is a superset of another branch ("B";) -- All equipment listed under "B" has exactly the same counterpart (regarding designation, Object Kind, structure, attributes etc.) under A, but not the viceversa. Connections between equipment under B is represented on several sheets of circuit diagrams. For this purpose all functionality of EB is used (frames, symbols, connections, potential sources/targets and similar). As explained -- all those shapes on those sheets are associated with objects under "B" branch of equipment.

Is is possible to programmatically reassociate all shapes on those sheets from "B" branch to their counterparts in "A" branch of equipment tree? I can't simply delete counterpart objects under "A" and move objects from "B" to "A" because counter objects under "A" are also already represented (as Secondary representation) on some other sheets, so after such operation (if it is possible) some objects under "A" should get some additional representations and their counterpart objects under "B" should lose all representations on sheets.

My idea is to iterate through equipment under "B" and find all associations to symbols on sheets and then via sheet operations deassociate those shapes from "B" objects and reassociate them with their counterparts objects under "A" branch. It looks possible for devices, units, cables (I suppose with OpExecSheetDelAssocSym and later on with OpExecSheetAssocSym). Related to wiring information I am not so sure. For potentials I found only operation for association "OpExecSheetAssocNet" but no operation for deassociation. I also don't know how to handle (if it is possible) source/target potential connections between sheets.

Does API allows such task, or there is some other way to achieve such goal? I appreciate any hint related to this.

Kind regards,
Žarko