Introduction

This article describes how to use a MicroStation CONNECT Report to export DGN cell count and other information. This capability was introduced with MicroStation CONNECT Update 15.

Reports

Reports Icon

MicroStation CONNECT introduced Reports. Reports is an analytic tool. It extracts alphanumeric data (DGN or business data) from your DGN file, model, elements or elsewhere. When Item Types are in use, Reports can extract Item instance data attached to your DGN model or elements.

With MicroStation CONNECT Update 15 and later you can add grouping and aggregates to a MicroStation CONNECT Report.

Cell Count Report Preview 1

Visit our reports page for more information, and to see other examples of Reports in action. Don't forget to visit MicroStation's Reports help documentation.

Post questions about Reports to the Be Communities MicroStation Forum.

Define a Cell Report

The precursor to this Cell Count Report is the simple Cell Report. Right-click that existing Report definition in the Report dialog, and choose Copy. Rename the Report to something appropriate, such as Cell Count Report.

Copy Cell Report Definition 1

Edit the Report Definition

In this example, we want to report cell names and cell counts. The Report category is named Cell Reports. The Report definition is named Cell Count Report …

Cell Count Report Definition 1

We'll be working with the new (for MicroStation CONNECT Update 15) options Groups & Aggregates and Summarize.

Report All Columns

When you define a Report having grouping, by default only the grouped columns are displayed. In this example of cell counting, that means by default only the cell count column is displayed — which leaves us in the dark about which cells have what count.

To make the cell name column visible, we must scroll down in the Report Properties pane to see the section labelled Groups and Aggregates. Choose the Column options button, and select All.

Cell Count Report All Columns

Add Grouping to the Report

A DGN model may contain multiple cell instances. Each named cell may be placed multiple times. We want to know how many of each cell exists in the DGN model. To report those quantities, we want to apply Grouping to our Report.

Click the Groups & Aggregates menu …

Cell Count Groups 1

Pay attention to the Groups Add/Remove button top-right. Click that button to add the columns that you want to group. In this example, choose the Origin column …

Cell Count Report Group 1

Next look at the Aggregates panel. It shows the new Origin group with the Count option automatically selected …

Cell Count Report Aggregate 1

If you preview the Report, you'll see the Origin column now displays the cell count. That doesn't look right, so in the Report definition, rename the Origin column to Count. That looks better …

Here's a preview of your cell count report …

Cell Count Report Preview 1

You can see the count of each cell name, but you can't see the total number of cells. Next, we'll add a total count aggregate.

Add Total Count to the Report

Click the Report Summarize menu. The summarize options in the top-right panel are empty …

Cell Count Report Summarize

Click the big green plus sign. MicroStation adds the Cell Name column to be summarized, with the Count option already elected. Click the check box to confirm you want to summarize the Cell Name …

Cell Count Report Summarize 2

Report Completed

Click the Report Preview button to see your finished report …

Cell Count Report Preview 2

Example DGNLib

Design Library file ReportExamples.dgnLib contains the Report definition described here. It is available, along with a sample CSV file and Excel file. More information here.