Java Barcode is a
Jasper Reports barcode generator which generates high quality 1D (linear) and 2D (matrix) barcodes in Jasper Reports projects.
Libraries Needed
How to generate barcodes in Jasper Reports using Java Barcode?
-
Draw barcodes on your Jasper report.
<image>
<reportElement x="265" y="44" width="100" height="50"/>
<imageExpression class="net.sf.jasperreports.engine.JRRenderable">
<![CDATA[new com.onbarcode.barcode.jasper.JasperRenderer(
com.onbarcode.barcode.jasper.BarcodeGenerator.draw(2, "12345", "", "X=2&Y=60"))]]>
</imageExpression>
</image>
BarcodeGenerator.draw method accepts 4 parameters:
the first is the barcode type in int,
the second is the barcode data to encode, in String,
the third is the supplement barcode data in String,
the last is the barcode settings String. More details about barcode settings string, please check
each barcode type property settings
How to generate barcodes using data from data source?
-
1. Define the data field in your jasper report
-
2. Draw barcodes on your Jasper report.
<image>
<reportElement x="265" y="44" width="100" height="50"/>
<imageExpression class="net.sf.jasperreports.engine.JRRenderable">
<![CDATA[new com.onbarcode.barcode.jasper.JasperRenderer(
com.onbarcode.barcode.jasper.BarcodeGenerator.draw(2, $F{data field} + "", "", "X=2&Y=60"))]]>
</imageExpression>
</image>
Java Reporting Barcode Generation Guide
Jasper Reports Barcode Generation
|
iReport Barcode Generation
|
Eclipse BIRT Barcode Generation
Barcode Generation Guide for .NET / Java Developers
.NET Barcode Generation
|
C# Barcode Generation
|
ASP.NET Barcode Generation
|
VB.NET Barcode Generation
Java Barcode Generation