Essentially, a DXF file is composed of pairs of codes and associated values. The codes, known as group codes, indicate the type of value that follows. Using these group code and value pairs, a DXF file is organized into sections composed of records, which are composed of a group code and a data item. Each group code and value are on their own line in the DXF file.
Each section starts with a group code 0 followed by the string SECTION. This is followed by a group code 2 and a string indicating the name of the section (for example, HEADER). Each section is composed of group codes and values that define its elements. A section ends with a 0 followed by the string ENDSEC.
It may be helpful to produce a DXF file from a small drawing, print it, and refer to it while reading the information presented in this section.
The overall organization of a DXF file is as follows:
APPID (application identification table)
BLOCK_RECORD (block reference table)
DIMSTYLE (dimension style table)
LAYER (layer table)
LTYPE (linetype table)
STYLE (text style table)
UCS (user coordinate system table)
VIEW (view table)
VPORT (viewport configuration table)
If you use the Select Objects option of the SAVE or SAVEAS command, the ENTITIES section of the resulting DXF file contains only the entities you select.