TBarcode1D_EAN128

EAN-128The component is used to create the EAN-128 barcode symbol. It's defined in the pEAN128 unit.

The EAN-128 barcode symbology is also known as UCC/EAN-128, UCC-128, USS-128, GS1-128, UCC.EAN-128, GTIN-128, UCC-12, EAN/UCC-13, EAN/UCC-14, etc. It is a subset of the more general Code 128 symbology. It was developed to provide a worldwide format and standard for exchanging common data between companies. An EAN-128 barcode is a Code 128 barcode and it is constructed like this:

  1. FNC 1: Function Character 1 in Code 128 symbology, It does not need to be entered in the Barcode or Data (only for Delphi/C++ Builder 2009 or later) property, and it will be automatically inserted. And it is not represented in the human readable text.
  2. AI: Application identifier, It is a 2, 3, or 4-digits number that identifies the type and format of the data which follows. By convention, the AI is enclosed in parentheses when printed below the barcode (the parentheses are only used for human readable text, and are not encoded in the barcode).
  3. Data: The data field, Its meaning and format are identified by the AI. For some AI fields, an extra check digit is required, you can set the AutoCheckDigit property to true to automatically calculate the check digit, and use the CheckStart and the CheckLength properties to decide which characters will be used to calculate the check digit.
  4. Code 128 check digit: Check digit in Code 128 symbology. It does not need to be entered in the Barcode or Data (only for Delphi/C++ Builder 2009 or later) property, and it will be automatically calculated even if the AutoCheckDigit property is set to false.

A single barcode may contain more than one type of information. The beginning of each new piece of information is marked by an AI. An FNC1 is required after each variable-length field (do not use FNC1 after the last data field, and do not use FNC1 if the maximal field length is used). For example, An EAN-128 barcode contains two pieces and the first pieces is variable-length field. It is constructed like this:

  1. FNC 1: Function Character 1 in Code 128 symbology, It does not need to be entered in the Barcode or Data (only for Delphi/C++ Builder 2009 or later) property, and it will be automatically inserted. And it is not represented in the human readable text.
  2. AI: First application identifier.
  3. Data: First data field. Its meaning and format are identified by first AI.
  4. FNC 1: Function Character 1 in Code 128 symbology, It need to be entered in the Barcode or Data (only for Delphi/C++ Builder 2009 or later) property, and it is not represented in the human readable text.
  5. AI: Second application identifier.
  6. Data: Second data field. Its meaning and format are identified by second AI.
  7. Code 128 check digit: Check digit in Code 128 symbology. It does not need to be entered in the Barcode or Data (only for Delphi/C++ Builder 2009 or later) property, and it will be automatically calculated even if the AutpCheckDigit property is set to false.

Note, the CheckStart and the CheckLength properties only work for last data field. For the CheckStart property, the index of first AI's first character is 1.

See also the TBarcode1D_Code128 component.

The EAN128 barcode symbol can be used together with a 4-column CC-A, a 4-column CC-B or a CC-C 2D symbol to create the EAN.UCC composite symbol. If you use the component together with the CC-A, CC-B or CC-C 2D barcode component that's in our 2D Barcode VCL Components package, it can be used as the Liner property's value of the CC-A, CC-B or CC-C 2D barcode component to create the EAN.UCC composite symbols. In such case, only the Barcode, Data (only for Delphi/C++ Builder 2009 or later), AutoCheckDigit, CheckStart, CheckLength, InitialSubSet, Height, DisplayText, TextPosition, TextAlignment, TextFont, TextVSpacing, and the TextHSpacing properties are useful, the value of other properties will be ignored and they will be set automatically depending on the settings of the 2D barcode component (the Link2D property will be set automatically depending on which 2D component is used). In addition, the Height property should be set to a value larger than zero, and the Image should not be normally set. If you use it together with other 2D components package, the Link2D property should be set by yourself.

Technical Details:
Properties:
Methods:
Events:

(*): The Data property, OnEncode, OnDecodeText, OnInvalidDataLength, and OnInvalidDataChar events are available only for the Delphi/C++ Builder 2009 or later.

Contents