1C:Barcode Printing control for 1C:Enterprise 8.3 platform
Use the control to generate a barcode. You can use the control only with 1C:Enterprise 8 products in workplaces that have a license to use 1C:Enterprise 8 software. The current control version is 9.0.2.2
Key features
CODETYPE_DATAMATRIX_ASCII,
CODETYPE_DATAMATRIX_BASE256,
CODETYPE_DATAMATRIX_TEXT,
CODETYPE_DATAMATRIX_C40,
CODETYPE_DATAMATRIX_X12,
CODETYPE_DATAMATRIX_EDIFACT
With the control, you can generate barcodes of the following formats: EAN8, EAN13, EAN13 AddOn 2, EAN13 AddOn 5, ITF14, RSS14, EAN128, Code39, Code39 Full ASCII, Code93, Code128, Code16k Industrial 2 of 5, Interleaved 2 of 5, CodaBar, PDF417, QR, GS1 databar extended stacked, DataMatrix ASCII, DataMatrix Base256, DataMatrix Text, DataMatrix C40, DataMatrix X12, DataMatrix Edifact. Supports automatic detection of the barcode format. Character value can be passed to the control with or without a check character. You can disable showing the barcode check character on the resulting barcode image. To ensure that barcode lines are within the print area, use the "Minimum width" and "Minimum height" properties that contain the minimum possible width and height of the printable area where the barcode can be fully displayed.
Appearance features
Text displayed on the barcode surface can be specified programmatically, regardless of the barcode content. You can change the font, the text position (at the top or at the bottom of the barcode), and the text display flag. You can also change the text color, the background color, and the barcode line color. The barcode background may be transparent. You can also change the rotation angle (90 degrees discretely) of the barcode with text.
Properties
Alias | Type | R | W | Description |
---|---|---|---|---|
CodeType | Number | + | + | The property contains a barcode type ID. Can take on of the following values: 0 (EAN8 code type) 1 (EAN13 code type) 2 (EAN128 code type) 3 (CODE39 code type) 4 (CODE128 code type) 5 (CODE16K code type) 6 (PDF417 code type) 7 (Industrial2of5 code type) 8 (Interleaved2of5 code type) 9 (Code39FullASCII code type) 10 (CODE93 code type) 11 (ITF14 code type) 12 (RSS14 code type) 13 (CodaBar code type) 14 (EAN13 AddOn 2 code type) 15 (EAN13 AddOn 5 code type) 16 (QR code type) 17 (GS1 databar extended stacked code type), 18 (DataMatrix ASCII code type), 19 (DataMatrix Base256 code type), 20 (DataMatrix Text code type), 21 (DataMatrix C40 code type), 22 (DataMatrix X12 code type), 23 (DataMatrix Edifact code type) |
CodeAuto | Boolean | + | + | If this property is True, the control will automatically attempt to determine the barcode type |
CodeIsRaw | Boolean | + | + | The property contains a flag indicating that the passed message has the check character |
CodeShowCS | Boolean | + | + | If the property is True, the check character will be included in the line placed on the barcode surface (the property only has meaning when this line can be displayed) |
CodeValue | String | + | + | The property contains a message to encode |
CodeCheckSymbol | String | + | - | The property contains a check character (if the barcode type uses it) |
CodeText | String | + | + | The property contains the text placed on the barcode surface (the property only has meaning when this line can be displayed). For EAN8 and EAN13 barcodes, the line must have 8 and 13 characters accordingly. |
CodeSentinel | Number | + | + | The property contains height of separator lines (in EAN8 and EAN13 only) in percent of text height |
CodeMinWidth | Number | + | - | The property contains the minimum possible width of the area where the barcode can be displayed |
Font | Font | + | + | The property contains the font used when displaying the line on the barcode surface (the property only has meaning when this line can be displayed). |
FontSize | Number | + | + | The property contains the font size in pixels |
FontCount | Number | + | - | The property contains the number of fonts installed in the system that the component can use |
TextColor | Color | + | + | The property contains the color used when displaying the line on the barcode surface (the property only has meaning when this line can be displayed). |
TextAlign | Number | + | + | The property specifies how to place the line displayed on the barcode surface (the property only has meaning when this line can be displayed). Can take one of the following values: 0 (center text) 1 (align text to the left) 2 (align text to the right) 3 (justify text) 4, 5, 6 (text placement options that are commonly used for EAN8 and EAN13 barcodes) |
TextPosition | Number | + | + | The property specifies how to place the line displayed on the barcode surface (the property only has meaning when this line can be displayed). Can take one of the following values: 0 (bottom) 1 (top) |
TextVisible | Boolean | + | + | The property indicates whether the barcode text must be displayed on its surface. This is relevant only for barcode types which use this line display |
BgColor | Color | + | + | The property sets the barcode fill background color. It has meaning only when a transparent background is not used. |
BgTransparent | Boolean | + | + | The property contains a flag indicating that the transparent background is used |
BarColor | Color | + | + | The property contains the color used to fill lines on the barcode surface |
CanvasRotation | Number | + | + | The property contains the barcode rotation angle (in degrees). Can take one of the following values: 0 90 180 270 |
CanvasXOffset | Number | + | + | (Not used) The property contains value of horizontal offset of the barcode image |
CanvasYOffset | Number | + | + | (Not used) The property contains value of vertical offset of the barcode image |
CanvasMargin | Number | + | + | (Not used) The property specifies the width of the border around the barcode image |
BarAlign | Number | + | + | (Not used) The property specifies the method of automatic positioning of the barcode image. Can take one of the following values: 0 (do not use auto align) 1 (align left) 2 (align center) 3 (align right) |
BarVerticalAlign | Number | + | + | The property specifies the method of automatic positioning of the barcode image. Can take one of the following values: 1 (top) 2 (center) 3 (bottom) |
ColumnCount | Number | + | + | The property sets the number of barcode columns. Relevant for PDF417. |
RowCount | Number | + | + | The property sets the number of barcode lines. Relevant for PDF417. |
AspectRatio | String | + | + | The property sets the aspect ratio of barcode modules. Relevant for PDF417. |
ECL | String | + | + | The property specifies the error correction level. Relevant for PDF417. |
CodeMinHeight | Number | + | - | The property contains the minimum possible height of the area where the barcode can be displayed |
QRErrorCorrectionLevel | Number | + | + | The property contains the value of QR code correction level. Can take on of the following values: 0 – L 1 – M 2 – Q 3 – H |
GS1DatabarRowCount | Number | + | + | The property contains the number of lines of barcode GS1 databar extended stacked |
Methods
Alias | Parameters | Return value | Description |
---|---|---|---|
GetBarcode | - | Image | The method returns the image of the generated barcode |
FontAt | Font Face Index (from 0 to FontCount-1) | String | Font Name by index |
FindFont | Font Name | True/False | The method sets the BgColor according to passed values of red, green, and blue color components |
NOTE Properties and methods are also covered in the control help |
Example of control use
Function GetBarcode(BarcodeWidth, BarcodeHeight) BarcodeParameters = New Structure; BarcodeParameters.Insert("Width", BarcodeWidth); BarcodeParameters.Insert("Height", BarcodeHeight); BarcodeParameters.Insert("CodeType", BarcodeType); BarcodeParameters.Insert("ShowText", True); BarcodeParameters.Insert("FontSize", FontSize); BarcodeParameters.Insert("TurnAngle", Number(TurnAngle)); BarcodeParameters.Insert("Barcode", Barcode); BarcodeParameters.Insert("TransparetBackground", TransparetBackground); BarcodeParameters.Insert("QRLevelCorrection", QRLevelCorrection); BarcodeParameters.Insert("Scale", Scale); BarcodeParameters.Insert("KeepProportions" , KeepProportions); BarcodeParameters.Insert("VerticalAlignment" , VerticalAlignment); BarcodeParameters.Insert("GS1DatabarRowsCount" , GS1DatabarRowsCount); Return EquipmentManagerServerCall.GetBarcodeImage(BarcodeParameters); EndFunction