BizCode Barcode Generator for Crystal Report
The most advanced barcode control for Crystal Report
Quick Overviews
  • Crystal Report .NET SDK
  • Linear & 2D barcode support
  • .NET 2.0/3.0/4.0 support
  • Support C#, VB.NET, etc
  • Multiple file formats support
How to Generate Code 128 in Crystal Reports
Code 128, also known as ANSI/AIM 128, USS Code 128, is a high density linear barcode capable of encoding the full 128-character ASCII character set and extended character sets. It is widely used in non-retail fields where a relatively large amount of data must be encoded in a relatively small amount of space.
Crystal Report Code 128 Generator SDK provides you perfect barcode generation solution in your Crystal Report. This .NET component provided by Business Refinery is strong-named, signed DLL with 100% C# managed code that completely runs in VB.NET and C# in .NET Framework 2.0, 3.0, and advanced version.
It is easy for developers to generate Code 128 in Crystal Report programs. Barcode parameters are pre-configured in barcode control for easy and quick generation. Developers may feel easy to adjust barcode properties such as barcode size, image, font, color, rotation, etc through VB.NET and C# in Crystal Report.
This page gives you detail information of how to generate Code 128 in Crystal Report and how to customize barcode properties of Code 128 via VB.NET and C#.
Code 128 Generator for Crystal Report Features
Encodable Characters Support to encode:
- Standard ASCII characters 0-127 (default: ISO/IEC 646)
- Extended ASCII characters 128-255 (default: ISO/IEC 8859-1)
Redistribution Once installed in a report, all other reports support barcode generation without other plug-ins
C# Managed Code The managed code is completely build in C# with strong-named signature DLLs
Various Image Formats The generated Code 128 can be freely displayed as Gif, Tiff, Bmp, Png or Jpeg image without the use of font
Rotation Flexibility Display barcodes in different angles (0, 90, 180, 270 degrees)
All Printers Compatible with all printers: low-resolution printers and high-resolution printers
Code 128 Generator for Crystal Report Requirements
Windows OS
-Microsoft Windows 7
- Windows Server 2008
- Windows Vista
- Windows Server 2003
- Windows XP
Development Environments
- .NET 2.0/3.0/4.0
- C#, VB.NET, Managed C++, Borland Delphi for.NET
- Visual Studio 2005/2008/2010
- Crystal Report (Runtime)
Install Code 128 Generator for Crystal Report
  1. Download Barcode Generator for Crystal Report Free Trial and unzip;
  2. Add "BusinessRefinery.Barcode.web.dll" to your ASP.NET project reference;
How to Insert Code 39 into Crystal Report
  1. Download Barcode Generator for Crystal Report and unzip. In the demo file, there are a "BarcodeDemoData.mdb" that including "ID", "CustomerId", and "CustomerName", and a "CustomerDataSet.xsd".
  2. Open your Visual Studio, create a new web project with "ASP.NET Crystal Reports Web Site" as template;
  3. Create a new report "Using the Report Wizard", and choose "Standard", and click "OK";
  4. In "Data" form, double click "Create New Connection", and expand "ADO.NET".
  5. In "ADO.NET" form, select "CustomerDataSet.xsd" file in your downloaded package, and click "Finish" button.
  6. Back at the "Data" form. Double click "table", then click "Next". In the "Fields" form, double click or drag and drop "ID", "CustomerID", "CustomerName" to "Fields to Display" and click "Finish";
  7. In CrystalReport1.rpt, add field "Barcode" to the report Section 3;
  8. Add "BusinessRefinery.Barcode.web.dll" to your project reference in "Solution Explorer";
  9. Right click "Default.aspx" in "Solution Explorer" and choose "View Code";
  10. Copy the following code accordingly and run the project.
Sample Codings to Generate Code 128 in Crystal Report
Run the projects
protected void Page_Load(object sender, EventArgs e)
OleDbConnection aConnection = new OleDbConnection(
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:/Demo/BarcodeDemoData.
OleDbDataAdapter dataAdapter = new OleDbDataAdapter
("select * from Customer", aConnection);
DataSet ds = new DataSet();
//add a new column named "Barcode" to the DataSet, the new column data
type is byte[]
ds.Tables[0].Columns.Add(new DataColumn("Barcode", typeof(byte[])));
Linear barcode = new Linear();
barcode.Type = BarcodeType.CODE128;
foreach (DataRow dr in ds.Tables[0].Rows)
barcode.Data = (int)dr["CustomerId"] + "";
byte[] imageData = barcode.drawBarcodeAsBytes();
dr["Barcode"] = imageData;
Protected Sub CrystalReportViewer1_Init(ByVal sender As Object, 
ByVal e As System.EventArgs) Handles CrystalReportViewer1.Init
Dim aConnection As New OleDbConnection
Data Source=C:/Demo/BarcodeDemoData.mdb"
Dim dataAdapter As New OleDbDataAdapter("select * from Customer",
Dim ds As New DataSet()
'add a new column named "Barcode" to the DataSet, the new column
data type is byte[]
ds.Tables(0).Columns.Add(New DataColumn("Barcode", GetType(Byte())))
Dim barcode As New Linear()
barcode.Type = BarcodeType.CODE128
For Each dr As DataRow In ds.Tables(0).Rows
barcode.Data = CInt(dr("CustomerId")) & ""
Dim imageData As Byte() = barcode.drawBarcodeAsBytes()
dr("Barcode") = imageData
End Sub