Page tree

Excel Import Plugin 19.0 LTR SP4 Documentation


The Excel Import plugin is an effective and useful tool, which is designed to allow you to import data or information from any Excel (.xls and .xlsx) or CSV (.csv and .txt) format files to MagicDraw and export data from a MagicDraw project into an Excel or a CSV file. The plugin works with MagicDraw version 18.0 and greater.

A typical spreadsheet or Excel file arranges numbers and text in numbered rows and letter-named columns. Data in these rows and columns may be in a form of line graphs, histograms, and charts, and with a very limited three-dimensional graphical display. However, only data organized in a simple spreadsheet style without graphs, histograms, charts, or graphics are importable into MagicDraw.

A comma-separated value or CSV file contains data in a form of numbers and text. A CSV file is a simple text file that consists of a sequence of characters or numbers called records. Each record is divided into fields and separated by delimiters such as a comma, semicolon, colon, or tab. These data are also transferrable into MagicDraw.

With Excel Import, you can import table headings from an Excel or a CSV file into MagicDraw as schema classes and import data in each row from the file as the instance specifications of the schema classes. The plugin can import composite headers as multiple schema classes.

Once importing data, you can use Excel Import to further modify the imported schema class and its instance specifications to map the schema class to a target element and create a class mapping that will be represented in a mapping diagram. You can also import data from an Excel or CSV file through the class mapping. However, the element the plugin will import varies according to the type of target element selected in the class mapping. Target elements that you can select are UML and SysML profiles, and a user model.

The following are three possible types of elements resulting from importing data through a class mapping:

  • If you select a target element type from a UML profile, the plugin will import data as the same element type in the UML meta model.
  • If you select a target element type from a SysML profile, for example, a requirement or a block, the plugin will import data as the same element type in the SysML profile.
  • If you select a target element type from a user model, for example, a class or a block, the plugin will import data as the instance specification of a user model.

You can also export the instance specifications or mapped elements into xls, xlsx, csv, or .txt format. The Excel Import plugin supports the following:

(i) Excel file

  • Filename extensions, .xls and .xlsx.
  • Importing multiple spreadsheets in a file at a time.
  • Table headings, rows, and merged cells.
  • Composite headers (a table with multiple headings in a pyramid shape).
  • Boolean, text, and number data types.
A Table with Composite Headers
A spreadsheet consisting of table headings, rows, merged cells, text, and number data types in an Excel file.

 (ii) CSV file

  • Filename extensions, .csv and .txt.
  • Delimiters such as comma (default, as shown in the figure below), semicolon, colon, tab, space, and others (you can choose another delimiter in the wizard later if you formatted your CSV file with something other than a comma, semicolon, colon, tab, or space).
  • One heading per file.

CSV File

  Using commas as delimiters in a CSV file.
  • No labels