Back to Devexpress

Serial Shipping Container Code (SSCC-18)

xtrareports-404260-feature-guide-to-devexpress-reports-use-report-controls-use-bar-codes-sscc.md

latest4.1 KB
Original Source

Serial Shipping Container Code (SSCC-18)

  • Feb 18, 2026
  • 3 minutes to read

The Serial Shipping Container Code (SSCC-18) is the 18-digit GS1 identification key used to identify a logistic unit. This unique identifier is composed of an Extension Digit, a GS1 Company Prefix, a Serial Reference, and a Check Digit.

SSCC is encoded as GS1-128 barcode. It is a subset of the Code 128 symbology.

Refer to the SSCC specification for more details.

Add the Bar Code to a Report

  1. Drag the XRBarCode item from the DX.25.2: Report Controls tab and drop it onto the report.

  2. Set the XRBarCode control’s Symbology property to SSCC (an object of the SSCCGenerator type).

  3. Assign a numeric value composed of 17 digits to the Text property. If the numeric value contains less than 17 digits, it is padded with zeros at the beginning so that the string value of the Text property contains exactly 17 characters. A numeric value with 17 digits is left intact. If 18 digits are specified, the last digit is truncated. A value with more than 18 digits causes an error.

  4. Specify common barcode properties.

Runtime Example

The following code creates the SSCC barcode and specifies its properties.

View Example: How to add a barcode to a report

csharp
using System;
using System.Collections.Generic;
using System.Drawing.Printing;
using System.Windows.Forms;
using DevExpress.XtraPrinting.BarCode;
using DevExpress.XtraReports.UI;
// ...
public XRBarCode CreateSSCCBarCode(string BarCodeText) {
    // Create a barcode control.
    XRBarCode barCode = new XRBarCode();

    // Set the barcode type to SSCC.
    barCode.Symbology = new SSCCGenerator();

    // Adjust the barcode's main properties.
    barCode.Text = BarCodeText;
    barCode.Width = 400;
    barCode.Height = 100;
    barCode.AutoModule = true;

    return barCode;
}
vb
Imports System
Imports System.Collections.Generic
Imports System.Drawing.Printing
Imports System.Windows.Forms
Imports DevExpress.XtraPrinting.BarCode
Imports DevExpress.XtraReports.UI
' ...
Public Function CreateSSCCBarCode(ByVal BarCodeText As String) As XRBarCode
    ' Create a barcode control.
    Dim barCode As New XRBarCode()

    ' Set the barcode's type to EAN 128.
    barCode.Symbology = New SSCCGenerator()

    ' Adjust the barcode's main properties.
    barCode.Text = BarCodeText
    barCode.Width = 400
    barCode.Height = 100
    barCode.AutoModule = True

    Return barCode
End Function

The code example below shows how to create a report with the SSCC barcode:

csharp
using DevExpress.XtraPrinting.BarCode;
using DevExpress.XtraReports.UI;
//...

var barCode = CreateSSCCBarCode("00106141411234567");

var report = new XtraReport() {
    Bands = {
        new DetailBand() {
            Controls = { barCode }
        }
    }
};
vb
Imports DevExpress.XtraPrinting.BarCode
Imports DevExpress.XtraReports.UI
'...

Private barCode = CreateSSCCBarCode("00106141411234567")

Private report = New XtraReport() With {
    .Bands = {
        New DetailBand() With {
            .Controls = { barCode }
        }
    }
}