Skip to main content
All docs
V26.1
  • Deutsche Post Leitcode

    • 2 minutes to read

    Deutsche Post Leitcode is a one-dimensional, numeric-only barcode symbology used by Deutsche Post for automated mail sorting and routing. The symbology encodes a fixed-length, 14-digit identifier that contains routing information (including postal codes and delivery identifiers).

    Deutsche Post Leitcode is based on the Interleaved 2 of 5 (ITF) symbology and includes a checksum to help detect data-entry and scanning errors.

    Deutsche Post Leitcode Barcode, DevExpress Barcode Generation API for .NET

    Refer to the following page for additional information: https://de.wikipedia.org/wiki/Leitcode

    Configure Deutsche Post Leitcode Settings

    Use the DeutschePostLeitcodeOptions class to configure Deutsche Post Leitcode barcode settings.

    The following code snippet creates an Deutsche Post Leitcode barcode and customizes its options:

    DevExpress Barcode Generator - Deutsche Post Leitcode barcode

    using DevExpress.Docs.Barcode;
    using DevExpress.Drawing;
    using System.Drawing;
    
    var leitOptions = new DeutschePostLeitcodeOptions();
    leitOptions.ShowText = true;
    leitOptions.Padding = new Padding(5);
    leitOptions.BorderWidth = 1;
    
    using var leitOptionsStream = new FileStream(Path.Combine(outDir, "barcode_symbology_deutsche_post_leitcode.png"), FileMode.Create, FileAccess.Write);
    using var leitOptionsGenerator = new BarcodeGenerator(leitOptions);
    leitOptionsGenerator.Export("12345678901234", leitOptionsStream, DXImageFormat.Png);
    

    Fluent API

    Use the DeutschePostLeitcodeOptionsBuilder class to configure Deutsche Post Leitcode barcode settings with the Fluent API.

    The following code snippet creates an Deutsche Post Leitcode barcode and customizes its options:

    DevExpress Barcode Generator - Deutsche Post Leitcode barcode

    using DevExpress.Docs.Barcode;
    using DevExpress.Drawing;
    using System.Drawing;
    
    var leitOptions = DeutschePostLeitcodeOptionsBuilder.Create()
        .WithShowText(true)
        .WithPadding(5)
        .WithBorderWidth(1)
        .Build();
    
    using var leitOptionsStream = new FileStream(Path.Combine(outDir, "barcode_symbology_deutsche_post_leitcode.png"), FileMode.Create, FileAccess.Write);
    using var leitOptionsGenerator = new BarcodeGenerator(leitOptions);
    
    leitOptionsGenerator.Export("12345678901234", leitOptionsStream, DXImageFormat.Png);