Reporting for CAD Administrators: Cell Count Reports

As a CAD Administrator or user, you have a real need to run a specific report, one showing each cell that has been placed into a design.

In the past, you may have even done this by “brute force” by using Edit>Select By Attributes. A tedious task at best, but effective if you wanted to know how many “Inlet Curb” or “CatchBasin” cells were in a particular file.

You may even remember, that in the early 2000’s Bentley provided a utility ( that would aggregate all the cell names, provide symbology information and a count of each cell in a particular file. It could be run against a model or even all models. The resulting report could be printed to screen or even to a text file. And that same utility was used right up until the release of the MicroStation CONNECT Edition.

Enter the MicroStation CONNECT Edition, with its robust reporting capabilities allowing for all that the old tool did but offers so much more.

Reports are typically thought of for use with Item Types and their properties. Reporting on the “Inlet Curb” or “CatchBasin” Item Types and displaying their properties in particular columns can certainly be created in the MicroStation CONNECT Edition. However, every MicroStation V8i or earlier user uses cells and no Item Types in their workflow. How can we continue to quantify the cells in your model, design file, WorkSet or even WorkSpace? In a word, Reports.

This Blog, the third in a series will focus on a common request, “needing a report of my WorkSet/Project, showing all models in all design files, the cell’s name, scale, origin and other information about the cell.”

The best place to create this report is not in the active file but rather a configured .dgnlib within your WorkSet, WorkSpace or Organizational standards. This allows everyone with that configured .dgnlib to have access to this report definition and other helpful CAD Management reports. That is not to say that it must be placed at one of these configuration levels, it can be placed anywhere within your configuration from the Personal.dgnlib to standards.cfg and anywhere in between.

We will start with a .Dgnlib, that has been placed into …\Configuration\Organization\Dgnlib. By placing the file in this location, MicroStation will make any reports it contains available for use by anyone using this WorkSpace/WorkSet. The file can also be “locked” using file permissions to be read-only for all but certain users. A copy of the .Dgnlib with this report and others has been provided for your use.

To create the report:

  • From the Drawing Workflow, pick the Analyze Ribbon Tab and Reports.
  • Next, create a New Category (or add to an existing category), calling it whatever you desire. In this example, I will stick with CAD Mgt Reports.
  • Create a New report definition called All Cells in WorkSet.
  • Then, pick the All Cells in WorkSet, and set Properties>Search Location>Location Type to Path.
  • Substitute your Location or desired Variable to locate your desired directory. Here I will use $(_USTN_WORKSETROOT).

Note: There are several Location Types that can be used. A simple Location Type of File or Model will run the report on the active file and model.

Setting this to Path expands our possibilities, here are just a few others.

$(_DGNDIR) will allow you to check only the files in the active directory. In a scenario where you have a /DGN directory with several disciplines underneath, for examples /DGN/Roadway and /DGN/Signals, this would allow you to run the report only on the Signals by opening a design from that specific directory.

$(_USTN_WORKSPACEROOT) will allow you to check all files within a particular WorkSpace. This will run the report on all Projects or WorkSets within the WorkSpace Root directory.

$(_USTN_WORKSETROOT) will allow you to check all the files within a particular WorkSet. It will run the report on the particular WorkSet you have selected.       

  • From Included Items, pick Item Types, there will be a drop down that appears.
  • Then from Include these Item Types, pick Select an Item Type>Dgn Elements, followed by Cells, selecting OK when complete.
  • From the right side of the dialog, pick Add these related items, Element resides in a Model >Models>Model resides in a Design File>Files. Click OK.
    • Currently, we are NOT using the Filtered By option. We can use this to limit what design files we review, such as a specific drainage file or pond file.
  • Then pick Columns under All Cells in WorkSet and pick Add columns.
  • Expand Files>General> File Name. Check File Name and pick OK or continue adding columns.
  • Then pick Columns under All Cells in WorkSet and pick Add columns.
  • Expand Cells>General. Check Cell Name, Cell Type, Expand Geometry and select Origin.
  • Expand Extended. Check Model and pick OK.
  • Next, you can preview your new All Cells in WorkSet. From Reports, pick Preview results.

Note: Don’t worry about the exact order of the columns, you can reorder the report columns via the Move Up and Move Down icons.

Note: The report definition, created in the .Dgnlib is configured at the Organizational level. Alternatively, you can import the report from the .Dgnlib into the active file if desired. This is found under Utilities on the Reports dialog.

Filtering Reports

You will take note that the report is based on all files as defined by the _USTN_WORKSETROOT variable. This includes all .dgn files and .Dgnlib files. This report is displaying every cell, including every Station Tick Mark in the main design file. To limit the results you can apply a filter to only view the design files (.dgn) and just particular cells located in particular design files.

For our example, we are going to get a cell count of Inlet Curbs, Pipe Culverts, Inlet Bottoms, Pipe Culverts and Catch Basins.

Select the Filter icon on the File Name column. Then, setting Show rows with value that to Contains, type pondrd.dgn into the field. Pick Filter and note the report is filtering only the pondrd.dgn file.

From here we can see all cells in a particular file, however, we want to get a count of several particular cells. To do so, select the Filter icon on the Cell Name column.

Select the following Cell Names, 200005, 210005, 210006, 232001, MH, MH1, MH2, selecting Filter when complete.

Next drag the column heading Cell Name to the area marked Drag a column header and drop it here to group by that column. The results are grouped by each Cell Name.

First Pipe Culverts, represented by the cell name 232001, shows 19, Inlet Curbs represented by the cell 210005 displays 73, Inlet Bottoms described by the cell 200005, display 18, while Pipe Culverts are represented by several cells, we will concern ourselves with cell 232001 showing 19 and 210006 with 13 and finally Catch Basins described by the cells, MH with 15, MH1 with 1 and MH2 with 6.

Keep in mind, rather than “massaging” the data herein MicroStation, the original report can be exported to Microsoft Excel and filtered and quantified there. Select Export results from the Reports dialog.

Everyone learns a bit differently, so the text of this blog may help some, the images, others and there is also a matching video as well. I have also included the .dgnlib for your use.

I hope you found this Blog informative. This is the third in a series on CAD Administration Reporting. If you have suggestions for needed reports from a CAD Administration basis, please comment on the Blog. You may just see your suggestion featured in the series!