CAD/D Macros & Utility Programs
There are two programming languages used for development in MicroStation Connect and OpenRoads Designer, VBA & MDL.
VBA programs can be run by selecting the desired Macro from the dropdown list on the Utilities tab and clicking the Play button. A list of available programs will be displayed. If no macros are listed, you may not have selected the NHDOT workspace before opening the drawing.
MDL programs can be loaded by selecting MDL Applications from the Utilities tab.
AttachAerial | Cell Tools | ManageUserPreferences | NHRef | Rotate Cells / Text | Sign Footing | SlopeSet | Station-Offset | Steel | Zero2Cell
AttachAerial
Used to attach raster files of aerial photos to the active model. Note that this macro will only work for NHDOT staff. Consultants working on NHDOT projects who wish to have copies of the images in the area of their project should download them from GRANIT. Visit NH GRANIT Available Layers for more information.
Cell Tools
The CellTool application provides some useful extensions to MicroStation’s standard cell placement tool. CellTool gives you the ability to:
- Place Active Cell with an interactive rotation angle
- Place Active Cell on a selected element with interactive rotation angle
- Place Active Cell on an element by partially deleting the target element to fit the cell.
- Place multiple copies of the active cell along or offset from a selected element at a given distance between each copy.

Detailed documentation is available on Bentley's Communities website.
ManageUserPreferences
This macro is used to backup your current user preference settings, restore previously backed up settings or reset your user preferences to the NHDOT default values.
VBA macros are accessed from the Utilities tab.
Select ManageUserPreferences and click Play.
A dialog box will appear with three options:
- Replace with Seed Files will copy the seed files associated with the version of MicroStation or OpenRoads Designer that you are using to the computer you are working on.
- Backup to N Drive will copy the files associated with the version of MicroStation or OpenRoads Designer that you are using from the computer you are working on to a location on the N drive.
- Restore from N Drive will copy the files associated with the version of MicroStation or OpenRoads Designer that you are using from the N drive to the computer you are using.
NHRef
See the NHRef page for details of this macro.
Rotate Cells / Text (EnvisionCad)
This tool is intended to rotate Text (Cells) to the View Angle. So first rotate the view along the roadway. In a 3D model rotate by 3 points. Hit all points in space so they get the same elevation, the first 2 define the rotation, the last point hit above the other two. Return to Top rotation and re-rotate if you hit on an element and tilted the plane.
Use Element Selector to drag box around cells or text you want to rotate. Click on the A Rotate Text tool and use the following Settings - Rotate by Angle, Reverse View Angle - uncheck/check to update view angle, Absolute, check Rotate entire Cell, click Update to Rotate them. Note that poles on the bottom side of the roadway will need to be selected again. In the Tool add 180 to the Z Rotation value and then Update.

Sign Footing
See the Sign Footing page for details of this macro.

SlopeSet
Used to add slope text to profiles, cross sections and typical sections. This macro measures slope between 2 data points and places text at a selected location. Note that text will always be placed along the X or Y axis regardless of drawing rotation. The active settings (level, color, style, etc.) will be used.
The text can be formatted as either a percent slope (%) or ratio (x:1).
Select the number of decimal places for the text.
The exaggeration option would typically be set to 5 for profile slopes since our profiles are usually drawn at a 5:1.
Text can be placed vertically (along the Y axis) by checking the Vertical Text box.
Click the Annotate Slope button after adjusting settings. You will be prompted to select the two points and then a location for the text.
Station-Offset (Ohio DOT)
See the Station Offset page for details of this macro.
Steel
The Steel toolbox has two icons, ‘Place Steel Section’ and ‘Steel Section Parameters’. Clicking on place steel icon will start placing a steel section. The steel section is chosen in the Tool Settings dialog. Additional placement parameters are in the Steel Section Parameters dialog, accessible using the Steel Section Parameters Icon.
Detailed documentation is available on the Bentley's Communities website.
Zero2Cell
Used to locate zero length lines and place a cell at that point. It is primarily used for shape file imports that contain points.
First select an area containing the zero length lines.
Use the keyin vba run Zero2Cell [cellname] [scale] substituting the name of the preferred cell for [cellname]. The [scale] is optional. If no scale is specified then the Annotation Scale will be used.
If the cells are not readily visible, select the cells and check that their Is Annotation property is set to True.