Exporting attribute fields to CAD as text

This workflow demonstrates how to export feature attributes to a CAD file as text elements using a point feature class and reserved CAD fields CADType and TxtValue. A common application for this workflow is to generate CAD text at the centroid of polygon features such as states, counties, or parcels.

The point feature is derived from an existing linear feature. It is used to provide a coordinate location for each text element in the CAD file. The resulting output CAD file will contain a text entity positioned at each point feature location.

Create the point feature class

Use the Feature To Point tool to create a new point feature class from an existing polygon feature layer.

Steps:
  1. Using the Search window Search Window, find and open the Feature To Point tool.
  2. Drag the polygon feature class from the table of contents or Catalog window into the Input Features text box.
    • Or, use the browse button Browse to navigate to the source data, and click Add.
  3. Click the Output Feature Class browse button Browse, navigate to a geodatabase, type a name for the new feature class, and click Save.
    • Or, accept the default path and feature class name.

Add reserved CAD fields to the attribute table

Adding the CADType field

The CADType field specifies the type of CAD entity to be generated. You will use the Field Calculator to specify the keyword "TEXT".

Steps:
  1. Right-click the feature layer in the table of contents, and click Open Attribute Table.
  2. Click the General Tabular Operations button Table Options on the attribute table menu bar, and click Add Field to open the dialog box.
  3. Type the field name CADType in the Name text box.
  4. Click the Type drop-down arrow, and click Text to assign the data type.
  5. Accept the default field length of 50.
  6. Click OK to close the dialog box and create the field.
  7. Right-click the CADType field name in the attribute table, and click Field CalculatorCalculator on the shortcut menu .
  8. Type "TEXT", including the double quotes, in the Expression text box.
  9. Click OK to run the tool.

    The CADType field now displays the value TEXT for all records.

Adding the field TxtValue

The TxtValue field specifies the value to be generated for each text entity. You will use the Field Calculator to calculate a value from an existing attribute.

Steps:
  1. Right-click the feature layer in the table of contents, and click Open Attribute Table.
  2. Click the General Tabular Operations button Table Options on the attribute table menu bar, and click Add Field to open the dialog box.
  3. Type the field name TxtValue in the Name text box.
  4. Click the Type drop-down arrow, and click Text to assign the data type.
  5. Accept the default field length of 50.
  6. Click OK to close the dialog box and create the field.
  7. Right-click the TxtValue field name in the attribute table, and click Field Calculator Calculator on the shortcut menu.
  8. Clear any existing values in the Expression text box.
  9. Double-click a field name in the Fields list that contains the values you want to export as text. This adds the field name to the Expression text box.

    For example [propertyaddress].

  10. Click OK to run the tool.

    The TxtValue field now displays the attribute values you will export as CAD text for each feature record.

Run the Export To CAD tool

Steps:
  1. Using the Search window Search Window, find and open the Export To CAD tool.
  2. Drag the new point feature layer containing the reserved CAD fields from the table of contents to the Input Features text box.
  3. Click the Output Type drop-down arrow, and choose a CAD format.
  4. Click the Output File browse button Browse, navigate to a folder, type a name for the new CAD file, and click Save.
    • Or, accept the default path and filename.
  5. Click OK to run the tool and generate the CAD file.

Verify your results by examining the CAD annotation feature class in the newly created CAD file dataset.

Related Topics


Published 6/8/2010