Programmed Customizations Programmed Customizations Programmed Customizations
 

MicroStation BASIC Macros

MicroStation BASIC Macros are BASIC programs that automate often-used, usually short sequences of operations. Many Bentley PowerMap-specific extensions have been added to the BASIC language to customize it for the MicroStation environment.

In its simplest form, a macro “drives” Bentley PowerMap in much the same way a human user does. Macros select tools and view controls, send key-ins, manipulate dialogs, modify elements, and more, using many of the tools documented in this guide. The obvious advantage of writing a macro to perform a task that could otherwise be done manually is automating mechanical and repetitive tasks. Several sample macros are supplied with Bentley PowerMap.

Macro code is stored in text files with .bas file extension. The macro language is BASIC with MicroStation-specific extensions. Compiled macros are stored in resource files with .ba extensions.

For information about developing your own macros, see MicroStation BASIC Help.

Running MicroStation BASIC macros