The Barcode report control offers various barcode styles to choose from. This saves you the time and expense of finding and integrating a separate component. As with other data-bound report controls, you can bind a barcode to data using the DataField property.
Apart from the barcode style, you can manage the alignment, color, background color, caption position, font, text, and check whether checksum is enabled in the Properties Window. There are more properties available with the Code49, PDF417, and QRCode barcode styles. Click the Barcode to reveal its properties in the Properties window. All of the properties specific to this report control are also available in the Barcode dialog.
Important Properties
The following properties help you to customize the specific barcode you need for your application:
Property | Description |
---|---|
Alignment | The horizontal alignment of the caption in the control. Select from Near, Center, or Far. See CaptionPosition for vertical alignment. |
AutoSize | When set to True, the barcode automatically stretches to fit the control. |
BackColor | Select a background fill color for the barcode. |
BarHeight | Set the height, in inches, of the barcode's bars. If the bar height exceeds the height of the control, this property is ignored. |
CaptionGrouping | Gets or sets a value indicating whether to add spaces between groups of characters in the caption to make long numbers easier to read. This property is only available with certain styles of barcode, and is ignored with other styles. |
CaptionPosition | The vertical alignment of the caption in the control. Select from None, Above, or Below. See Alignment for horizontal alignment. None is selected by default, and no caption is displayed. |
CheckSumEnabled | Some barcode styles require a checksum and some have an optional checksum. CheckSumEnabled has no effect if the style already requires a check digit or if the style does not offer a checksum option. |
Font | Set the font for the caption. Only takes effect if you set the CaptionPosition property to a value other than None. |
ForeColor | Select a color for the barcode and caption. |
NarrowBarWidth |
Also known as the X dimension, this is a value defining the width of the narrowest part of the barcode. Before using an extremely small value for this width, ensure that the scanner can read it. This value is specified in pixels (for example, 10 pixels). |
NWRatio | Also known as the N dimension, this is a value defining the multiple of the ratio between the narrow and wide bars in symbologies that contain bars in only two widths. For example, if it is a 3 to 1 ratio, this value is 3. |
QuietZone | Sets an area of blank space on each side of a barcode that tells the scanner where the symbology starts and stops. You can set separate values for the Left, Right, Top, and Bottom. |
Rotation | Sets the amount of rotation to use for the barcode. You can select from None, Rotate90Degrees, Rotate180Degrees, or Rotate270Degrees. |
Style | Sets the symbology used to render the barcode. See the table below for details about each style. |
SupplementOptions | Sets the 2/5-digit add-ons for EAN/UPC symbologies. You can specify Text, DataField, BarHeight, CaptionPosition, and Spacing for the supplement. |
Text | Sets the value to print as a barcode symbol and caption. ActiveReports fills this value from the bound data field if the control is bound to the data source. |
Limitations
Some barcode types may render incorrectly and contain white lines in the Html and RawHtml views. However, this limitation does not affect printing and scanning. The list of barcode types that may render with white lines in the Html and RawHtml views:
With the control selected on the report, in the Commands section at the bottom of the Properties window, you can click the Property dialog command to open the dialog.
General
Name: Enter a name for the control that is unique within the report. This name is displayed in the Document Outline and in XML exports. You can only use underscore (_) as a special character in the Name field. Other special characters such as period (.), space ( ), forward slash (/), back slash (\), exclamation (!), and hyphen (-) are not supported.
Tag: Enter a string that you want to persist with the control. If you access this property in code, it is an object, but in the Properties window or Property dialog, it is a string.
Visible: Clear this check box to hide the control.
DataField: Select a field from the data source to bind to the control.
Text: Enter static text to show in the textbox. If you specify a DataField value, this property is ignored.
Autosize: Clear this check box to prevent the barcode from automatically resizing to fit the control.
Location: Select a value to indicate whether and where to display a caption for the barcode. You can select from Above, Below, or None.
Text alignment: Select a value to indicate how to align the caption text. You can select from Center, Near, or Far.
Barcode Settings
Style: Enter the type of barcode to use. ActiveReports supports all of the most popular symbologies:
Table of all included symbologies
Notes: The RSS and QRCode styles have fixed height-to-width ratios. When you resize the width, the height is automatically calculated.
When you choose a style that offers supplemental options, the additional options appear below.
Symbology Name | Example | Description |
---|---|---|
Ansi39 | ANSI 3 of 9 (Code 39) uses upper case, numbers, - , * $ / + %. This is the default barcode style. | |
Ansi39x | ANSI Extended 3 of 9 (Extended Code 39) uses the complete ASCII character set. | |
BC412 | Data BC412 uses 35 characters, 0 - 9 and A - Z. It is designed for semiconductor wafer identification. | |
Codabar | Codabar uses A B C D + - : . / $ and numbers. | |
Code_11 | Encodes the numbers 0 through 9, the hyphen (-), and start/stop characters. It is primarily used in labeling telecommunications equipment. | |
Code_128_A | Code 128 A uses control characters, numbers, punctuation, and upper case. | |
Code_128_B | Code 128 B uses punctuation, numbers, upper case and lower case. | |
Code_128_C | Code 128 C uses only numbers. | |
Code_128auto | Code 128 Auto uses the complete ASCII character set. Automatically selects between Code 128 A, B and C to give the smallest barcode. | |
Code_2_of_5 | Code 2 of 5 uses only numbers. | |
Code_93 | Code 93 uses uppercase, % $ * / , + -, and numbers. | |
Code25intlv | Interleaved 2 of 5 uses only numbers. | |
Code39 | Code 39 uses numbers, % * $ /. , - +, and upper case. | |
Code39x | Extended Code 39 uses the complete ASCII character set. | |
Code49 | Code 49 is a 2D high-density stacked barcode containing two to eight rows of eight characters each. Each row has a start code and a stop code. Encodes the complete ASCII character set. | |
Code93x | Extended Code 93 uses the complete ASCII character set. | |
DataMatrix | Data Matrix is a high density, two-dimensional barcode with square modules arranged in a square or rectangular matrix pattern. | |
EAN_13 | EAN-13 uses only numbers (12 numbers and a check digit). It takes only 12 numbers as a string to calculate a check digit (CheckSum) and add it to the thirteenth position. The check digit is an additional digit used to verify that a bar code has been scanned correctly. The check digit is added automatically when the CheckSumEnabled property is set to True. | |
EAN_13 with the add-on code | EAN-13 may include the add-on code to the right of the main code. The add-on code may include up to 5 supplemental characters. | |
EAN_8 | EAN-8 uses only numbers (7 numbers and a check digit). | |
EAN128FNC1 | EAN-128 is an alphanumeric one-dimensional representation of Application Identifier (AI) data for marking containers in the shipping industry. This barcode is now obsolete. You should use UCC/EAN–128 instead which provides similar functionality with better performance. | |
GS1QRCode |
GS1QRCode is a subset of the QR Code. The GS1 QR Code is a 2D symbol that denotes the Extended Packaging URL for a trade item. It is processed to obtain one URL address associated with the trade item identified by the Global Trade Item Number (GTIN). GS1 QR Code requires the mandatory association of the GTIN and Extended Packaging URL. GS1 QR Code allows to encode GS1 System Application Identifiers (AI) into QR Code 2D barcodes. Limitation: Kanji, CN, JP and Korean characters. |
|
HIBCCode128 | HIBCCode128 barcode uses the Code128 symbology. It encodes Primary Data and Secondary Data using slash (/) as delimiter. It is used in the health care products industry for identification purpose. | |
HIBCCode39 | HIBCCode39 barcode uses the Code39 symbology, with the Code39OptionalCheckDigit property set to True. It encodes 'Primary Data' and 'Secondary Data' using slash (/) as delimiter. It is used in the health care products industry for identification purpose. | |
IATA_2_of_5 | IATA_2_of_5 is a variant of Code_2_of_5 and uses only numbers with a check digit. | |
IntelligentMail | Intelligent Mail, formerly known as the 4-State Customer Barcode, is a 65-bar code used for domestic mail in the U.S. | |
IntelligentMailPackage | IntelligentMailPackage is more efficient in terms of processing and tracking mails than Intelligent Mail barcode. | |
ISBN | International Standard Book Number barcode is a special form of the EAN-13 code and is used as a unique 9-digit commercial book identifier. | |
ISMN | Internationally Standard Music Number barcode is a special form of the EAN-13 code. It is used for marking printed musical publications. | |
ISSN | International Standard Serial Number barcode is a special form of the EAN-13 code. It is used to identify serial publications, publications that are issued in numerical order, such as the volumes of a magazine. | |
ITF14 | Interleaved Two of Five This code is used to mark cartons and palettes that are including goods with an EAN-13 code. One digit is added in front of the EAN-13 code to mark the packing variant. | |
JapanesePostal | This is the barcode used by the Japanese Postal system. Encodes alpha and numeric characters consisting of 18 digits including a 7-digit postal code number, optionally followed by block and house number information. The data to be encoded can include hyphens. | |
Matrix_2_of_5 | Matrix 2 of 5 is a higher density barcode consisting of 3 black bars and 2 white bars. | |
MaxiCode |
MaxiCode is special polar barcode that uses 256 characters. It is used to encode a specific amount of data. |
|
MicroPDF417 |
MicroPDF417 is two-dimensional (2D), multi-row symbology, derived from PDF417. Micro-PDF417 is designed for applications that need to encode data in a two-dimensional (2D) symbol (up to 150 bytes, 250 alphanumeric characters, or 366 numeric digits) with the minimal symbol size. MicroPDF417 allows you to insert an FNC1 character as a field separator for variable length Application Identifiers (AIs). To insert FNC1 character, set “\n” for C#, or “vbLf” for VB to Text property at run time. |
|
MicroQRCode |
MicroQRCode is a two-dimensional (2D) barcode that is designed for applications that use a small amount of data. It can handle numeric and alphanumeric data as well as Japanese kanji and kana characters. This symbology can encode up to 35 numeric characters. |
|
MSI | MSI Code uses only numbers. | |
Pdf417 | Pdf417 is a popular high-density 2-dimensional symbology that encodes up to 1108 bytes of information. This barcode consists of a stacked set of smaller barcodes. Encodes the full ASCII character set. It has ten error correction levels and three data compaction modes: Text, Byte, and Numeric. This symbology can encode up to 1,850 alphanumeric characters or 2,710 numeric characters. | |
Pharmacode | Pharmacode represents only numeric data from 3 to 131070. It is a barcode standard used in the pharmaceutical industry for packaging. It is designed to be readable despite printing errors. | |
Plessey | Plessey uses hexadecimal digits to encode. It is a one-dimensional barcode used mainly in libraries. | |
PostNet | PostNet uses only numbers with a check digit. | |
PZN | PZN Pharmaceutical Central/General Number uses the same encoding algorithm as Code 39 but can carry only digits – 0123456789. The number of digits supported for encoding are 6 or 7. The letters 'PZN' and checksum digit are automatically added. It is mainly used to identify medicine and health-care products in Germany and other German-speaking countries. | |
QRCode | QRCode is a 2D symbology that is capable of handling numeric, alphanumeric and byte data as well as Japanese kanji and kana characters. This symbology can encode up to 7,366 characters. | |
RM4SCC | Royal Mail RM4SCC uses only letters and numbers (with a check digit). This is the barcode used by the Royal Mail in the United Kingdom. | |
RSS14 | RSS14 is a 14-digit Reduced Space Symbology that uses EAN.UCC item identification for point-of-sale omnidirectional scanning. The RSS family of barcodes is also known as GS1 DataBar. | |
RSS14Stacked | RSS14Stacked uses the EAN.UCC information with Indicator digits as in the RSS14Truncated, but stacked in two rows for a smaller width. RSS14Stacked allows you to set Composite Options, where you can select the type of the barcode in the Type drop-down list and the value of the composite barcode in the Value field. |
|
RSS14Stacked CCA | RSS14Stacked with Composite Component - Version A. | |
RSS14StackedOmnidirectional | RSS14StackedOmnidirectional uses the EAN.UCC information with omnidirectional scanning as in the RSS14, but stacked in two rows for a smaller width. | |
RSS14Truncated | RSS14Truncated uses the EAN.UCC information as in the RSS14, but also includes Indicator digits of zero or one for use on small items not scanned at the point of sale. | |
RSSExpanded |
RSSExpanded uses the EAN.UCC information as in the RSS14, but also adds AI elements such as weight and best-before dates. RSSExpanded allows you to insert an FNC1 character as a field separator for variable length Application Identifiers (AIs). To insert FNC1 character, set “\n” for C#, or “vbLf” for VB to Text property at run time. |
|
RSSExpandedStacked |
RssExpandedStacked uses the EAN.UCC information with AI elements as in the RSSExpanded, but stacked in two rows for a smaller width. RSSExpandedStacked allows you to insert an FNC1 character as a field separator for variable length Application Identifiers (AIs). To insert FNC1 character, set “\n” for C#, or “vbLf” for VB to Text property at run time. |
|
RSSLimited | RSS Limited uses the EAN.UCC information as in the RSS14, but also includes Indicator digits of zero or one for use on small items not scanned at the point of sale. RSSLimited allows you to set Composite Options, where you can select the type of the barcode in the Type drop-down list and the value of the composite barcode in the Value field. |
|
RSSLimited CCA | RSS Limited with Composite Component - Version A. | |
SSCC_18 | SSCC_18 is an 18-digit Serial Shipping Container Code. It is used to identify individual shipping containers for tracking purposes. | |
Telepen | Telepen has 2 different modes - alphanumeric-only and numeric-only. Both modes require a start character, a check digit, and a stop character. It is mainly used in manufacturing industries. | |
UCCEAN128 | UCC/EAN –128 complies to GS1-128 standards. GS1-128 uses a series of Application Identifiers to encode data. This barcode uses the complete ASCII character set. It also uses FNC1 character as the first character position. Using AI's, it encodes best before dates, batch numbers, weights, and more such attributes. It is also used in HIBC applications. | |
UPC_A | UPC-A uses only numbers (11 numbers and a check digit). | |
UPC_A with the add-on code | UPC-A may include the add-on code to the right of the main code. The add-on code may include up to 5 supplemental characters. | |
UPC_E0 | UPC-E0 uses only numbers. Used for zero-compression UPC symbols. For the Caption property, you may enter either a six-digit UPC-E code or a complete 11-digit (includes code type, which must be zero) UPC-A code. If an 11-digit code is entered, the Barcode control will convert it to a six-digit UPC-E code, if possible. If it is not possible to convert from the 11-digit code to the six-digit code, nothing is displayed. | |
UPC_E0 with the add-on code | UPC-E0 may include the add-on code to the right of the main code. The add-on code may include up to 5 supplemental characters. | |
UPC_E1 | UPC-E1 uses only numbers. Used typically for shelf labeling in the retail environment. The length of the input string for U.P.C. E1 is six numeric characters. | |
UPC_E1 with the add-on code | UPC-E1 may include the add-on code to the right of the main code. The add-on code may include up to 5 supplemental characters. |
Bar Height: Enter a value in inches (for example, .25in) for the height of the barcode.
Narrow Bar Width (also known as X dimension): Enter a value in points (for example, 0.8pt) for the width of the narrowest part of the barcode. Before using an extremely small value for this width, ensure that the scanner can read it.
Tip: For accurate scanning, the quiet zone should be ten times the Narrow Bar Width value.
Narrow Width Bar Ratio: Enter a value to define the multiple of the ratio between the narrow and wide bars in symbologies that contain bars in only two widths. For example, if it is a 3 to 1 ratio, this value is 3. Commonly used values are 2, 2.5, 2.75, and 3.
A quiet zone is an area of blank space on either side of a barcode that tells the scanner where the symbology starts and stops.
Left: Enter a size in inches of blank space to leave to the left of the barcode.
Right: Enter a size in inches of blank space to leave to the right of the barcode.
Top: Enter a size in inches of blank space to leave at the top of the barcode.
Bottom: Enter a size in inches of blank space to leave at the bottom of the barcode.
Note: The units of measure listed for all of these properties are the default units of measure used if you do not specify. You may also specify cm, mm, in, pt, or pc.
A checksum provides greater accuracy for many barcode symbologies.
Compute Checksum: Select whether to automatically calculate a checksum for the barcode.
Note: If the symbology you choose requires a checksum, setting this value to False has no effect.
Code49 Options are available for the Code49 barcode style.
Grouping: Indicates whether to use grouping for the Code49 barcode. The possible values are True or False (default). If Grouping is set to True, any value not expressed by a single barcode is expressed by splitting it into several barcodes.
GroupNumber: Enter a number between 0 (default) and 8 for the barcode grouping. When the Group property is set to 2, the grouped barcode's second symbol is created. When invalid group numbers are set, the BarCodeDataException is thrown.
Code128 has three settings that work in conjunction: Dpi, BarAdjust, and ModuleSize. This property only applies to the barcode style EANFNC1. You can improve the readability of the barcode by setting all three properties.
- Dpi: Sets the printer resolution. Specify the resolution of the printer as dots per inch to create an optimized barcode image with the specified Dpi value.
- BarAdjust: Sets the adjustment size by dot units, which affects the size of the module and not the entire barcode.
- ModuleSize: Sets the horizontal size of the barcode module.
DataMatrix Options are available for the DataMatrix barcode style.
EccMode: Select the Ecc mode from the drop-down list. The possible values are ECC000, ECC050, ECC080, ECC100, ECC140 or ECC200.
Ecc200 Symbol Size: Select the size of the ECC200 symbol from the drop-down list. The default value is SquareAuto.
Ecc200 Encoding Mode: Select the encoding mode for ECC200 from the drop-down list. The possible values are Auto, ASCII, C40, Text, X12, EDIFACT or Base256.
Ecc000_140 Symbol Size: Select the size of the ECC000_140 barcode symbol from the drop-down list.
Structured Append: Select whether the barcode symbol is part of the structured append symbols. The possible values are True or False.
Structure Number: Enter the structure number of the barcode symbol within the structured append symbols.
File Identifier: Enter the file identifier of a related group of the structured append symbols. If you set the value to 0, the file identifier symbols are calculated automatically.
EAN128FNC1 Options are available for the EAN128FNC1 barcode style.
DPI: Specify the printer resolution.
Module Size: Enter the horizontal size of the barcode module.
Bar Adjust: Enter the adjustment size by dot units, which affects the size of the module and not the entire barcode.
GS1Composite Options are available for the RSS14Stacked and RSSLimited barcode styles.
Type: Select the type of the composite barcode from the drop-down list. The possible values are None or CCA. CCA (Composite Component - Version A) is the smallest variant of the 2-dimensional composite component.
Value: Enter the expression to set the value of the composite barcode.
Mode: Select the mode of the MaxiCode barcode. The available values are Mode2 to Mode6.
MicroPDF417 Options are available for the MicroPDF417 barcode style.
Compaction Mode: Select the type of the compaction mode from the drop-down list. The possible values are Auto, TextCompactionMode, NumericCompactionMode, or ByteCompactionMode.
Version: Select the version from the drop-down box to set the symbol size.
Segment Index: The segment index of the structured append symbol. The valid value is from 0 to 99998, and less than the value in Segment Count.
Segment Count: The segment count of the structured append symbol. The valid value is from 0 to 99999.
File ID: The file id of the structured append symbol. The valid value is from 0 to 899.
MicroQRCode Options are available for the MicroQRCode barcode style.
ErrorLevel: Select the error correction level for the barcode from the drop-down list. Valid values are M, L, or Q. The available Error Level values change depending on the version you select.
Version: Enter the version of the MicroQRCode barcode style. Valid values are M1, M2, M3, or M4. The maximum amount of data can be stored in version M4.
Mask: Select the pattern for the barcode masking from the drop-down list. Valid values are Mask00, Mask01, Mask10, or Mask11.
Encoding: Select the barcode encoding from the drop-down list.
PDF417 Options are available for the Pdf417 barcode style.
Columns: Enter column numbers for the barcode. Values for this property range from 1 to 30. The default value is -1 which automatically determines column numbers.
Rows: Enter row numbers for the barcode. Values range between 3 and 90. The default value is -1 which automatically determines row numbers.
ErrorLevel: Enter the error correction level for the barcode. Values range between 0 and 8. The error correction capability increases as the value increases. With each increase in the ErrorLevel value, the size of the barcode increases. The default value is -1 for automatic configuration.
PDF 417 Barcode Type: Select the PDF417 barcode type form the drop-down list. The possible values are Normal or Simple. Simple is the compact type in which the right indicator is neither displayed nor printed.
QRCode Options are available for the QRCode barcode style.
Model: Select the model for the QRCode barcode style from the drop-down list. The possible values are Model1, the original model or Model2, the extended model. For GS1QRCode, Model1 is not supported.
ErrorLevel: Select the error correction level for the barcode from the drop-down list. The possible values are L (7% restorable), M (15% restorable), Q (25% restorable), and H (30% restorable). The higher the percentage, the larger the barcode becomes.
Version: Enter the version of the QRCode barcode style. Version indicates the size of the barcode. As the value increases, the barcode's size increases, enabling more information to be stored. Specify any value between 1 and 14 when the Model property is set to Model1 and 1 to 40 for Model2. The default value is -1, which automatically determines the version most suited to the value.
Mask: Select the pattern for the barcode masking form the drop-down list. Mask is used to balance brightness and offers 8 patterns in the QRCodeMask enumeration. The default value is Auto, which sets the masking pattern automatically, and is recommended for most uses.
- Mask000 (i+j) mod 2 = 0
- Mask001 i mod 2 = 0
- Mask010 j mod 3 = 0
- Mask011 (i+j) mod 3 = 0
- Mask100 (( i div 2)+(j div 3)) mod 2 = 0
- Mask101 (ij) mod 2 + (ij) mod 3 = 0
- Mask110 ((ij) mod 2 +(ij) mod 3) mod 2 = 0
- Mask111 ((ij)mod 3 + (i+j) mod 2) mod 2 = 0
Connection: Select whether to use the connection for the barcode. The possible values are True or False. This property is used in conjunction with the ConnectionNumber property. This property is not applicable to GS1QRCode barcode.
ConnectionNumber: Enter the connection number for the barcode. Use this property with the Connection property to set the number of barcodes it can split into. Values between 0 and 15 are valid. An invalid number raises the BarCodeData Exception. This property is not applicable to GS1QRCode barcode.
Encoding: Select the barcode encoding from the drop-down list.
RssExpandedStacked Options are available for the RSSExpandedStacked barcode style.
Row Count: Enter the number of the barcode stacked rows.
Supplementary Options are available for UPC_A, UPC_E0, UPC_E1, EAN_13, and EAN_8 barcode styles.
Supplement DataField: Select the data field for the barcode supplement.
Supplement Value: Enter the expression to set the value of the barcode supplement.
Caption Location: Select the location for the supplement caption from the drop-down list. The possible values are None, Above or Below.
Supplement Bar Height: Enter the bar height for the barcode supplement.
Supplement Spacing: Enter the spacing between the main and supplement barcodes.
Appearance
Fore color: Select a color to use for the bars in the barcode.
Background color: Select a color to use for the background of the control.
Rotation: Select a value indicating the degree of rotation to apply to the barcode. You can select from None, Rotate90Degrees, Rotate180Degrees, or Rotate270Degrees.
Font
Name: Select a font family name to use for the caption.
Size: Choose the size in points for the font.
Style: Choose from Normal or Italic.
Weight: Choose from Normal or Bold.
Decoration: Select check boxes for Underline and Strikeout.
GDI Charset: Enter a value to indicate the GDI character set to use. For a list of valid values, see MSDN Font.GDICharSet Property.
GDI Vertical: Select this checkbox to indicate that the font is derived from a GDI vertical font.