Skip To Content

esri_attributes_delete (AutoLISP)

This function deletes the ArcGIS for AutoCAD attribute values and XRECORDs from the specified entity, which will force the feature to assume all default values. If you include a field_list, only those specified fields attribute values are deleted.

Syntax

(esri_attributes_delete ename [field_list])

Arguments

  • ename | AutoCAD entity name | required | The AutoCAD entity name of the feature.
  • field_list | list | optional | An list of field names as individual strings:

Example usage

This will remove the value of the Pavement field from the selected entity. The field remains a part of the feature layer. The values for the field will defer to the default value when displayed.

(esri_attributes_delete (car (entsel)) (list "Pavement"))

Result example usage

This will remove the value of the Pavement field from the selected entity. The field remains a part of the feature layer. The value for the field will defer to the default value, and returns a list of true:

(T)

Return values

This function returns a value.

  • If successful, it returns a list of true: (T)
  • If failed, it returns a list with the first value of nil; then an associated list is returned containing the key value Error and an associated error message as a string: (nil ("Error" . "<message>")).

Failed return values

A failed return value can occur for any of the following reasons:

  • (nil ("Error" . "Missing required argument."))

    The required argument was not provided.

  • (nil ("Error" . "A field name was not found."))

    One of the listed field names is not valid.