Code 39 Extended
- 2 minutes to read
Code 39 Extended, also known as Full ASCII Code 39, encodes all 128 ASCII characters. The symbology uses the $, /, %, and + symbols as shift characters. Combine a shift character with the following character to encode a Full ASCII value.
Examples
Configure Barcode Settings (Code39ExtendedOptions)
Use the Code39ExtendedOptions class to configure code 39 extended barcode settings.
The following code snippet creates an Code 39 Extended barcode and customizes its options:

using DevExpress.Docs.Barcode;
using DevExpress.Drawing;
using System.Drawing;
var code39ExtOptions = new Code39ExtendedOptions();
code39ExtOptions.ShowText = true;
code39ExtOptions.Padding = new Padding(5);
code39ExtOptions.BorderWidth = 1;
code39ExtOptions.WideNarrowRatio = 3.0f;
code39ExtOptions.CalculateChecksum = true;
using var code39ExtOptionsStream = new FileStream(Path.Combine(outDir, "barcode_symbology_code39_extended.png"), FileMode.Create, FileAccess.Write);
using var code39ExtOptionsGenerator = new BarcodeGenerator(code39ExtOptions);
code39ExtOptionsGenerator.Export("Code39 ext: !@#$%", code39ExtOptionsStream, DXImageFormat.Png);
Configure Barcode Settings (Fluent API)
Use the Code39ExtendedOptionsBuilder class to configure code 39 extended barcode settings with Fluent API.
The following code snippet creates an Code 39 Extended barcode and customizes its options:

using DevExpress.Docs.Barcode;
using DevExpress.Drawing;
using System.Drawing;
var code39ExtOptions = code39ExtOptionsBuilder.Create()
.WithShowText(true)
.WithPadding(5)
.WithBorderWidth(1)
.WithWideNarrowRatio(3.0f)
.WithCalculateChecksum(true)
.Build();
using var code39ExtOptionsStream = new FileStream(Path.Combine(outDir, "barcode_symbology_code39_extended.png"), FileMode.Create, FileAccess.Write);
using var code39ExtOptionsGenerator = new BarcodeGenerator(code39ExtOptions);
code39ExtOptionsGenerator.Export("Code39 ext: !@#$%", code39ExtOptionsStream, DXImageFormat.Png);
Symbology-Specific Options
| Property | Description |
|---|---|
| CalculateChecksum | Gets or sets whether to calculate and add a check character to barcode data. |
| WideNarrowRatio | Gets or sets the wide bar to a narrow bar ratio. |
See Also