How To: Export to AutoCAD DWG or DXF format and maintain attributes
There are two methods to convert attributes from a geodatabase feature class attribute table to CAD using Export to CAD. This article will detail both methods that can be used for this process.
Note: The steps in this article apply only to a file or personal geodatabase feature class. These steps will not work if the input data are in shapefile format.
Tips and tricks to assist with this conversion process, and better control data output, are provided in the following Knowledge Base articles:
- How to: Export Geodatabase Feature Classes to CAD
- How to: Set Line Thickness when exporting to AutoCAD
- How To: Create AutoCAD BLOCKS with attributes from ArcGIS point features
The better known method to convert feature attributes to CAD is to label the geodatabase feature class with appropriate labels in ArcMap, and convert those labels to annotation in the geodatabase. This can get very cluttered if there are several attributes to convert. The method outlined below provides instructions on managing multiple attribute conversions.
Warning: If geodatabase annotation is to be exported to CAD, only create labels with the Standard Label Engine, not Maplex. Some annotation types, such as splines, that can be created with Maplex, are not supported in CAD programs so annotation created with Maplex should not be used for this purpose.
Warning: Annotation stored in the map cannot be exported to CAD
A more complex method for this conversion process is to create BLOCK entities in the output AutoCAD file and attach editable TAGs to the blocks to store attributes that can be accessed in AutoCAD. This process begins with creating a seed file in AutoCAD that contains the block name and definition, with associated TAG names that are to store attributes from the geodatabase feature class.
- Create a seed file in AutoCAD that contains the BLOCK definition, together with the TAG names that will be populated with attribute values from the geodatabase feature class. Here are the requirements:
- The TAG names must be identical to the names of the attributes in the geodatabase feature class, and are case-sensitive.
- Only text fields from the geodatabase attribute table can be converted to TAGs in the output AutoCAD file.
Note: To convert values from numeric fields in the attribute table, you will need to add new Text fields to the feature class attribute table, and calculate those numeric values into the new fields.
- Add the following fields with the indicated definitions to the attribute table of the data to be converted:
- CadType, Text field, length 15, populated with the word "Insert"
- RefName, Text field, length sufficient to store the block name from the AutoCAD file. This field is populated with the name of the BLOCK the feature will be converted to.