The requested page is not available for the requested platform. You are viewing the content for Default platform.

Code 93 Extended

  • 2 min to read

Short Description

It is possible, using Code 93's "Full ASCII Mode" to encode all 128 ASCII characters. This is accomplished by using the ($), (/), (%), and (+) symbols as "shift" characters. These characters combined with the single character that follows indicate which Full ASCII character is to be used.

Barcode - Code 93 Extended

Bar Code Properties

The type of a bar code control's Symbology property is Code93ExtendedGenerator.

The following property is specific to the Code 93 Extended type.

  • BarCodeGeneratorBase.CalcCheckSum

    Gets or sets whether to calculate a checksum for the bar code.

    Note

    A checksum of a Code 93 Extended bar code can contain characters that are not supported by this bar code symbology. For this reason, the checksum is not included in the Code 93 Extended bar code's displayed text.

Examples

The following code creates a Code 93 Extended bar code and specifies its main properties.

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

    // Set the bar code's type to Code 93 Extended.
    barCode.Symbology = new Code93ExtendedGenerator();

    // Adjust the bar code's main properties.
    barCode.Text = BarCodeText;
    barCode.Width = 400;
    barCode.Height = 100;

    // Adjust the properties specific to the bar code type.
    ((Code93ExtendedGenerator)barCode.Symbology).CalcCheckSum = false;

    return barCode;
}

To add the XRBarCode to a report band, handle the report's XRControl.BeforePrint event.

using System.Drawing.Printing;
// ...

private void XtraReport1_BeforePrint(object sender, PrintEventArgs e) {
    this.Detail.Controls.Add(CreateCode93ExBarCode("012345678"));
}