An Example of Exporting to Excel 2010 and 2013

This help file applies to an out-of-date version of MainBoss.
The most recent version of MainBoss is MainBoss 4.2.2.
For the latest version of this help file can be found here.

< Previous section  |  Table of Contents  |  Index  |  Next section >

The previous section showed how to export to Microsoft Excel 2007. This section does the same with Excel 2010 and 2013 (and repeats some of the information so that it's all in one section).

The first step is to create a file containing the data schema for unit data. You do this with the GenerateImportSchema verb:

mbutility gis /si:unit /out:unitschema.xml +excel

This writes the schema into a file called unitschema.xml.

The next step is to export the data:

mbutility ex /si:unit /out:data.xml /on:mymb

This exports data from a database with the organization name mymb, and writes the data into a file named data.xml.

The next step is to modify the data file's XML code so that it refers to the schema file. Start the Windows wordpad command and read in the data file. The second line will look like this:

<dsunit xmlns="">

Using Wordpad, edit the line so that it looks like this:

<dsunit xmlns=""
xsi:schemaLocation=" unitschema.xml">

Note that this line ends with the name of the file containing the schema (followed by the characters ">). Once you've made these changes, save the file.

The data file is now ready to be used by Excel. If you have Microsoft Office 2010, here's what you do:

  1. Start Excel.
  2. Click "File" in the upper left hand corner of the Excel window.
  3. In the resulting window, click "Options" (at the bottom of the window).
  4. In the resulting window, click "Customize Ribbon".
  5. Under "Main Tabs", checkmark "Developer" if it isn't already checkmarked.
  6. Click OK to close the options window.
  7. In the main Excel window, click "Developer" in the ribbon.
  8. In the XML section of the ribbon, click "Import".
  9. In the resulting window, specify the name of the data file (in our example data.xml).

Excel gives you the option of reading the data file into the current spreadsheet or into a new one.

< Previous section  |  Table of Contents  |  Index  |  Next section >