Crystal Reports Barcode Code 128 Generator
How to generate, print barcode Code 128 in Crystal Reports for .NET. No font ufl required. Free download.


How to create, display, embed print Code 128 barcode labels Crystal Reports report viewer in .net project without using font ufl. Free download.



  • Powerful report tool, completely integrated into .NET Framework 2.0 and above
  • 100% built and created in the managed Visual C#.NET
  • Provide free C# or VB sample code for Code 128 barcode creation in Crystal Reports
  • Easily create Code Set A, Code Set B and Code Set C of Code 128 in Crystal Reports
  • Change fields to Code 128 barcode image by simple clicks
  • Print Code 128 barcode image in a specific orientation, such as 0, 90, 180, etc
  • Offer royalty-free developer license for this Crystal Reports Code 128 Barcode SDK
Crystal Reports Code 128 Barcode Library Overview
KA.Barcode for Crystal Reports lets you integrate .NET applications (ASP.NET & WinForms) with Crystal Reports during runtime to build powerful reporting solution. .NET programmers have full access to the properties such as barcode height, margin, X-dimension etc. The properties could be changed by writing C# or VB code.
Code 128 Barcode Overview
Code 128 is a linear barcode appended with a mandatory check digit which was based on ISO/IEC 15417. Start characters A, B and C of Code 128 define the corresponding code set to be used initially in the symbol.
Code 128 Valid Character Set
  • Standard ASCII values: 0-128
  • Extended ASCII Values in accordance with ISO 8859-1: 128-255
Code 128 Data Encoding in Crystal Reports for .NET

Code 128 encoding characters set

Code 128 barcode supports the following characters
  • All 128 Full ASCII characters defined in ISO/IEC 646
  • Extended ASCII characters are also supported with Function Character (FNC4) used. (By default are values 128 - 255 of ISO/IEC 8859-1, Latin Alphabet 1)
  • 4 non-data function characters
  • 4 code set selection characters
  • 3 Start characters
  • 1 Stop character
In the Crystal Reports for .NET project, you need provide ASCII and extended ASCII chars to barcode generator component only.

Code 128 Code sets

Code 128 barcode has three unique data character code sets
  • Code Sets A
  • Code Sets B
  • Code Sets C
Each code set includes a subset of the full ASCII character set together with various auxiliary characters.

Code 128 characters length

The Code 128 specification does not specify the maximum number of characters in a single barcode image.

However some Code 128 application standards may has defined the limits of characters in Code 128 barcode symbology.

Code 128 symbol check digit

Code 128 barcode contains a mandatory check digit (checksum) character, which is based on module 103 (mod 103).
Crystal Reports Code 128 Barcode SDK Download
Users are free to download our Code 128 Barcode Generation SDK for Crystal Reports Evaluation. The evaluation version of this barcode generator is composed of the following items:
  • KeepAutomation.Barcode.Crystal.dll
  • KACrystalData.mdb
  • ProductDataSet.xsd
  • End User License Agreement
  • User Manual and Order Page
Evaluation version of Crystal Reports Code 128 Barcode SDK is available for an unlimited period of time. But a "KA Barcode" watermark is included in Code 128 barcode image generated with this evaluation version. So the evaluation version can not be used to commercial applications.
Crystal Reports Code 128 Barcode Creation in ASP.NET
  1. Open your Visual Studio and create a new web project with "ASP.NET Crystal Reports Web Site" as template.
  2. Create 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". In "Fields" form, add all three columns in the table "Product" and click "Finish".
  6. Add field "Barcode" to the report Section 3 in CrystalReport1.rpt.
  7. Locate "KeepAutomation.Barcode.Crystal.dll" to your project reference.
  8. Compile the sample codes below and run the 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");
aConnection.Open();

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

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

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

foreach (DataRow dr in ds.Tables[0].Rows)
{
code128.CodeToEncode = (int)dr["ProductId"] + "";
byte[] imageData = code128.generateBarcodeToByteArray();
dr["Barcode"] = imageData;
}
CrystalReportSource1.ReportDocument.Load(Server.MapPath("CrystalReport1.rpt"));
CrystalReportSource1.ReportDocument.SetDataSource(ds.Tables[0]);
CrystalReportSource1.DataBind();

}
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")
aConnection.Open()

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

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

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

For Each dr As DataRow In ds.Tables(0).Rows
code128.CodeToEncode = CInt(dr("ProductId")) & ""
Dim imageData As Byte() = code128.generateBarcodeToByteArray()
dr("Barcode") = imageData
Next
CrystalReportSource1.ReportDocument.Load(Server.MapPath("CrystalReport1.rpt"))
CrystalReportSource1.ReportDocument.SetDataSource(ds.Tables(0))
CrystalReportSource1.DataBind()

End Sub
Code 128 Barcode Properties
If you want to know more information on Code 128, please view this Code 128 barcode properties page.
Free Trial DownloadCrystal Code 128Code 128 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 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-A for Crystal ReportUPC-E for Crystal Reportmore
KeepAutomation provides complete barcode automation solutions. We recommend the customers use high quality document controls: ASP.NET Document Viewer, ASP.NET MVC Document Viewer, Document Viewer ASP.NET C#, ASP.NET PDF Viewer, ASP.NET Word Viewer, ASP.NET Excel Viewer, ASP.NET PDF Editor, MVC PDF Viewer, ASP.NET Annotate PDF, c# pdf sdk, 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.