[CONNECT U12] Monitor EC data change best practice?


this my question is more about best practice, not specifically targeted to C++ or C#. C# is preferred in my current project, but when the solution will be available in C++ only, no problem.

Situation: There is an element with custom EC data attached. The data are available in Properties (Element Information) dialog and can be modified by a user. Such change is saved to persistent storage (DGN V8 file) by MicroStation automatically.

Question: Is it possible and what is recommended approch to monitor such change to be able to react on the change (e.g. to modify the element size/shape/etc.)?

I have not done any testing or research yet, but I can imagine that XAttribute changed event is fired when EC data are changed, but it seems to me a bit complicated (go through the whole path from XAttribute, test whether it's EC data or not and to what element it belongs). Maybe there is some other solution available, e.g. to monitor EC data particularly or to hook system responsible for rendering EC data in GUI?

With regards,


Parents Reply
  • Hi Dominic,

    I don't think this is correct at all. If you look at most BIM workflows

    I am not sure whether your reaction is that my formulation (i-model is read only) is wrong or you disagree with the concept or read only repository in a context of e.g. BIM workflow.

    Technically, i-model in Power products is read only, regardless .i.dgn or .imodel is used. End of story.

    I do not know how i-model is used in ConceptStation product, my assumption (but I have nearly zero knowledge here) is they used i-model in different way as standard repository.

    But e.g. iModelJS, next generation of i-model, is also strictly read only format, and modifications are stored as "change transactions", so from users' perspective it looks like read/write format, but it's not. This approach is not new and is used by many products, probably all code repository and versioning systems (where Git is I guess direct inspiration for iModelJS) work this way, also Adob Lightroom stores all picture modifications as a chain of time ordered transcations, but original data are never modified.

    So, there is a big difference between a dgn and i.dgn which has all the vertical's information exposed.

    Technically there is nearly no difference between .dgn and .i.dgn, the format is the same, but as Jon wrote, data is converted into different structures when published to i-model. It's primarily about data optimization, but not primarily about format change: e.g. SmartSolid is converted from complicated structure storead as cell with huge amount of custom data to standardized representation, vertical applications convert data from proprietary UserAttributes and XAttributes structures to EC schemas and EC classes. They can do the same when working with original DGN, but from historical and subtle technical reasons they do not in current versions.

    it is faster/more efficient to use this format to monitor and react to changes?

    In context of MicroStation the question does not make sense, because i-model is read only, so no change can be propagated to this format after it's created.



    P.S. It seems we have gone far from my original question....