[MSCE U8 c++] how to associate one element with another in different DGN model under same file?

and could not find the dependency API you mentioned

Why you want to use DependencyAPI? It is very low API, where it is not expected it is used by 3rd party developer (even when it is possible). There are other tools / options / classes available, but what is the best can be discussed only when required functionality is known.

Refers to this reply from Jan. What are the currently used api and classes to associate the elements?

Parents
  • Hi amender,

    What are the currently used api and classes to associate the elements?

    The problem is that you do not bother to answer my question why do you want to associate element :-(

    There are different ways, how to "associate" elements (to establish an association), providing different set of features.

    and could not find dependency API

    Did you try to search SDK documentation for "dependency" keyword?

    I received many results, including Element Dependencies chapter, with further links to several C APIs and DependencyManager, but the search also found Relationship Manager chapter (which is probably recommended place, where to start, because it provides more complex functionality than low level DependencyManager).

    to associate one element with another in different DGN model under same file?

    In the context of the same DGN file, to remember a combination of element ID and model ID is enough.

    [MSCE U8 c++]

    What is the reason so old MicroStation version is used? Update 8 was released 3 years ago and from user's perspective, anything older than let's say Update 14 is extremely buggy and slow. The latest Update 16.2 looks quite fine and last few releases bring also substantial performance optimization.

    Regards,

      Jan

  • The search also found Relationship Manager chapter, which is probably recommended place

    If you had searched this Forum for Relationship Manager, you would have found this answer from ...

    It's very rare that an application would need the sophistication and complexity associated with the RelationshipManager. The animator in Microstation is the only subsystem which requires it, for all the other subsystems the DependencyManager API's are more than sufficient

    DependencyAPI is very low API, where it is not expected it is used by 3rd party developer

    Why shouldn't it be used by a third-party developer?  It's a published API, documented and with header files.  Where does Bentley Systems advise us not to use it?

    I agree that it's low-level, and could be improved using object-oriented refactoring.  The same is true of other parts of the SDK.

    to have element A be associated to element B so that if I delete B, A would be deleted

    The Dependency Manager provides exactly that capability.  Here's an example.

     
    Regards, Jon Summers
    LA Solutions

    Answer Verified By: amender carapace 

Reply
  • The search also found Relationship Manager chapter, which is probably recommended place

    If you had searched this Forum for Relationship Manager, you would have found this answer from ...

    It's very rare that an application would need the sophistication and complexity associated with the RelationshipManager. The animator in Microstation is the only subsystem which requires it, for all the other subsystems the DependencyManager API's are more than sufficient

    DependencyAPI is very low API, where it is not expected it is used by 3rd party developer

    Why shouldn't it be used by a third-party developer?  It's a published API, documented and with header files.  Where does Bentley Systems advise us not to use it?

    I agree that it's low-level, and could be improved using object-oriented refactoring.  The same is true of other parts of the SDK.

    to have element A be associated to element B so that if I delete B, A would be deleted

    The Dependency Manager provides exactly that capability.  Here's an example.

     
    Regards, Jon Summers
    LA Solutions

    Answer Verified By: amender carapace 

Children