How to enable or disable menu items in MicroStation CE ??


We need to enable or disable menu items based on the user who uses our add-on. We have developed the add-on using C++.

How this can be achieved in MS ? Please provide example for this.


Rama. Shrinivasan

Parents Reply Children
  • In the above screen capture the Buttons(for eg. View attributes, Apply display style, Copy view, etc.) inside the tab groups(for eg. Presentation, Tools, etc.) needs to be disabled.

    I do not think it can be achieved easily, because MicroStation standard GUI is not designed to be accessed by 3rd party code directly..

    The question is why to do it? The functionality will be still there through key-ins, view menus and maybe also mouse context menu.

    What you can (probably) do is to replace the definitions (or maybe complete ribbon) by own definition, which will contain proper show expression or  feature aspect definition.

    We need to enable or disable

    A ribbon item definition can contain show expression (show/hide) and feature aspect (enable/disable) conditions. They are evaluated when the ribbon is created or reloaded (which is quite time expensive process). Individual specification, when item is evaluated, can be defined using sync item definition (e.g. to enable icon when an element is selected).

    For more details, see Ribbon chapter in MicroStation API documentation.

    Please provide example for this.

    As far I as I know there is no example available, but the description in API documentation is descriptive.

    With regards,