UPC-A Barcode Generation in Crystal Reports

How to Create UPC-A Barcode in Crystal Reports Using C# or VB Demo
  • Advanced and powerful UPC-A barcode generation control for Crystal Reports
  • Completely developed in C#.NET and compatible with any .NET Framework environment
  • Generate and print UPC-A images in Visual C# and Visual Basic .NET
  • Easy to print scannable & readable UPC-A barcode images for Crystal Reports in no time
  • Able to customize UPC-A parameters, like SupplementCode, SupplementHeight & SupplementSpace
  • Display UPC-A in Gif, Tiff, Bmp, Png and Jpeg images or as graphic objects
  • Automatically calculate and add checksum character for UPC-A barcode
Introduction of Crystal Reports UPC-A Barcode Control
KA.Barcode Generator for Crystal Reports is an easy-to-use and robust barcode generation component that allows developers to quickly and easily add barcode generation and printing functionality in Crystal Reports. The generated barcodes strictly conform to related barcode standards and barcode specifications.
Description of UPC-A Barcode
UPC stands for Universal Product Code. UPC-A is the most common form of UPC codes that consists of 12 digits to encode goods sold at point-of-sale in North America.
UPC-A Encodable Characters
  • UPC-A Encodable Characters: numeric digits 0-9
  • UPC-A Structure: 1 digit for Number System, 5 digits for Manufacturer Code, 5 digits for Product Code and 1 digit for checksum that will be automatically added by our software
Download of Crystal Reports UPC-A Barcode Control
Download this UPC-A Barcode Control for Crystal Reports Evaluation for free! This advanced Crystal Reports Barcode Library evaluation version contains:
  • User Manual and Order Page
  • End User License Agreement
  • KeepAutomation.Barcode.Crystal.dll
  • KACrystalData.mdb
  • ProductDataSet.xsd
Users are allowed to use this Crystal Reports UPC-A Barcode Library Evaluation to generate advanced and professional UPC-A barcode image without time limitation. But users need to buy our applicable license for business applications because barcode image generated with the trial version will include a "KA Barcode" watermark randomly.
Generation of Crystal Reports UPC-A Barcode in ASP.NET
  1. Create a new web project with "ASP.NET Crystal Reports Web Site" as template in your Visual Studio.
  2. Establish a new report "Using the Report Wizard", choose "Standard", and click "OK".
  3. In "Data" form, double click "Create New Connection", and expand "ADO.NET".
  4. Add "ProductDataSet.xsd" file in "ADO.NET" form, and click "Finish" button.
  5. In "Data" form, add table "Product" and click "Next".
  6. In "Fields" form, add all three columns in the table "Product" and click "Finish".
  7. Add field "Barcode" to the report Section 3 in CrystalReport1.rpt.
  8. Locate reference "KeepAutomation.Barcode.Crystal.dll" to your project.
  9. Use the sample codes below and run your project.
C# Sample code
     protected void Page_Load(object sender, EventArgs e)
OleDbConnection aConnection = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:/KACrystalData.mdb");

OleDbDataAdapter dataAdapter = new OleDbDataAdapter("select * from Product",aConnection);
DataSet ds = new DataSet();

//Add the Barcode column to the DataSet
ds.Tables[0].Columns.Add(new DataColumn("Barcode", typeof(byte[])));

BarCode upca = new BarCode();
//Barcode settings
upca.Symbology = KeepAutomation.Barcode.Symbology.UPCA;
upca.ImageFormat = System.Drawing.Imaging.ImageFormat.Png;

foreach (DataRow dr in ds.Tables[0].Rows)
upca.CodeToEncode = (int)dr["ProductId"] + "";
byte[] imageData = upca.generateBarcodeToByteArray();
dr["Barcode"] = imageData;

VB Sample code
     Protected Sub Page_Load(sender As Object, e As EventArgs)
Dim aConnection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:/KACrystalData.mdb")

Dim dataAdapter As New OleDbDataAdapter("select * from Product", aConnection)
Dim ds As New DataSet()

'Add the Barcode column to the DataSet
ds.Tables(0).Columns.Add(New DataColumn("Barcode", GetType(Byte())))

Dim upca As New BarCode()
'Barcode settings
upca.Symbology = KeepAutomation.Barcode.Symbology.UPCA
upca.ImageFormat = System.Drawing.Imaging.ImageFormat.Png

For Each dr As DataRow In ds.Tables(0).Rows
upca.CodeToEncode = CInt(dr("ProductId")) & ""
Dim imageData As Byte() = upca.generateBarcodeToByteArray()
dr("Barcode") = imageData

End Sub
View this detailed guide to generate UPC-A barcode image in .NET WinForms with this Crystal Reports Barcode Control. Free C# and VB sample codes are also provided.
Properties of UPC-A Barcode
We kindly offer a specific description of UPC-A barcode properties here to help your customize barcode image.
Free Trial DownloadCrystal UPC-AUPC-A PropertiesUsing C#Using VB.NETUsing ASP.NETUsing .NET WinformsData Matrix for Crystal ReportPDF417 for Crystal ReportQR Code for Crystal ReportmoreCodabar for Crystal ReportCode 39 for Crystal ReportCode 128 for Crystal ReportEAN-8 for Crystal ReportEAN-13 for Crystal ReportEAN 128 for Crystal ReportIntelligent Mail for Crystal ReportInterleaved 2 of 5 for Crystal ReportISBN for Crystal ReportITF-14 for Crystal ReportRM4SCC for Crystal ReportUPC-E for Crystal Reportmore
KeepAutomation provides complete barcode automation solutions for Business Application, Enterprise Developement Project, and mobile applications. We recommend the customers use high quality ASP.NET html5 document viewer, c# pdf sdk, C# merge PDF files, Split PDF in C#, C# View, edit PDF online , C# Convert PDF to Tiff, C# Convert PDF to text, txt, .net imaging sdk, C# PDF metadata edit from RasterEdge.com.