Python

DgnElementSetTool class

Copied from the MicroStationAPI Help Documentation

The DgnElementSetTool class can be used to implement an element pick or an element modify command.

It simplifies dealing with the common element sources. Basic tool operation is to populate an ElementAgenda from the active fence, selection sets, or user locate. The tool's _OnElementModify method will then be called for each entry in the ElementAgenda.

DgnElementSetTool Common Usage

The following sequence of member function calls will occur in the common case where the tool requires a datapoint to identify the target element and another datapoint to accept the modification (_NeedAcceptPoint -> True) …

DgnElementSetTool Single Datapoint Usage

The following sequence of member function calls will occur in the case where the tool requires a single datapoint to identify the target element and to accept the modification (_NeedAcceptPoint -> False, _WantDynamics -> False) …

  • _OnPostInstall
  • _OnDataButton

    DgnElementSetTool Enumerations

    DgnElementSetTool uses several enumerations that are defined for C++. The documentation didn't make it into the Python documentation. I've copied them here.

    Visit the State Machine examples Download page.

    Python Manager

    Use MicroStation's Python Manager to find and execute the script.

    Questions

    Post questions about MicroStation programming to the MicroStation Programming Forum.