Importing DXF Attributes into MapInfo Pro - MapInfo_Pro - 2023

MapInfo Pro Help

Product type
Software
Portfolio
Locate
Product family
MapInfo
Product
MapInfo > MapInfo Pro
Version
2023
Language
English
Product name
MapInfo Pro
Title
MapInfo Pro Help
First publish date
1985
Last updated
2023-09-12
Published on
2023-09-12T16:39:16.995549

Some DXF files contain textual information associated with graphic objects. In DXF, this is done by creating a block that contains the graphic objects and the textual information (stored in "attributes"). This block is then inserted into the drawing in one or more places, with possibly different data values in each case. There is no database structure imposed on attributes. For example, you might have two types of objects in your DXF file with the following attributes:

Pipes:	WIDTH
		TYPE (sewer, water, storm sewer, etc.)
		MATERIAL
Streets:	NAME
		ADDRESS_RANGE

When MapInfo Pro creates a tabular database from a DXF file, it must decide on a database structure. All the records in a Table contain the same fields. MapInfo Pro builds a database structure by scanning the entire DXF file for all attributes in the layers that are being imported, and creating a union of these fields. The data type of each field is determined by the contents of the attributes.

For example, when all attributes with a given name contain a number, the resulting MapInfo Pro field is a numeric data type.

Continuing the examples above, when pipes and streets are both imported into the same DXF file, the database structure is as follows:

  1. ADDRESS_RANGE
  2. MATERIAL
  3. NAME
  4. TYPE
  5. WIDTH

Most well-designed DXF files put objects of different types in different layers. The above DXF file probably contains 2 layers: pipes (which holds all the pipes of the map) and streets (which hold all the streets of the map). Run DXF Import twice, importing a different layer each time. You would create two MapInfo Pro tables, one with the correct pipe structure, and one with the correct street structure.

When you load both layers of our sample DXF file into one MapInfo Pro table, the records for the pipes have blank or zero values for the NAME and ADDRESS_RANGE fields. Likewise, WIDTH, TYPE, and MATERIAL are blank for the street records.

Note: It takes much longer to import attributes from a DXF file into MapInfo Pro than it does to import files with no attributes. The entities section of the DXF file must be read twice. We recommend that you run the import several times, checking to make sure that you are loading the correct layers and using the correct coordinate transformation, before importing the data attributes.