API Documentation > CorelDRAW > 2025-v26
DataFields class
Represents a collection of all object-data fields (or DataField objects) for all objects defined in a document
Syntax:
Class DataFields
Remarks:
The DataFields class represents a collection of all object-data fields (or DataField objects) for all objects defined in a document. By default, CorelDRAW create four data fields: Name, Cost, Comments, and CDRStaticID. The Cost and Comments fields are for your convenience and can be edited or deleted as required. The Name and CDRStaticID fields are used by CorelDRAW to identify objects and cannot be edited or deleted.
Properties:
Name Description
_NewEnum Returns an enumerator that iterates through a collection
Application Gets the application to which the object belongs
Count Gets the number of items in the collection of DataFields
Item Gets a reference to a specified DataField, in base 1
Parent Gets the parent of which this object is a child
Methods:
Name Description
Add Adds a field
AddEx Adds a data field
AddEx2 Adds data fields along with element name
IsPresent Returns True if a data field by the given name was already defined for the document