IDAutomation.com, Inc. |
Your Source for Quality Symbology |
Home: Products: PDF417 Barcode Font and Encoder PDF417 Font and Encoder FAQ & Support Manual: |
A license is required for each computer this
software is installed on; |
In this package we provide multiple font encoders as well as all of our PDF417 components.
If you are printing with the font, you MUST use our encoder to format the data you want to print with the PDF417 font. The "AdditionalFonts.zip" file includes PostScript and Macintosh fonts.
The "IDAutomation_PDF417FontEncoder.exe" program should be installed on all Windows® systems. It installs the encoder application, Visual Basic 6 example, MS Office macros, Crystal Reports UFL and an ActiveX DLL.
Other encoders and components such as the .NET Forms Control & DLL, ASP.NET Web Control, Java Class and the DataMatrix Java Package (which includes the applet and servlet) are included in the ZIP file.
PDF417 FAQ (Frequently Asked Questions) |
The implementation of PDF417 as a font consists of both the encoder and the font. The purpose of the encoder is to convert the data to be encoded into proper bar and space patterns formatted to our PDF417 barcode font. It is necessary to use the encoder because of the complexity of the symbology and the required Reed Solomon error correction.
The benefits include high scalability with operating system, application and printer independence. These are best described in our Font Quality Statements.
Can I encode and scan extended characters such as © ® ë ö ?
The answer is yes! It is possible to scan and encode extended characters provided you do the following:
Performing a Word mail-merge using Excel as the data source |
PDF417 barcodes can be created in a Word mail-merge if Excel is used as the data source with the following procedure:
Using the VBA macro with MS Access |
This is an example of using the PDF417 encoder with multiple fields using our sample database.
NOTE: The ActiveX Control provided in this package is easier to use in Access than the VBA macro with the font. Information about using this control is provided at the ActiveX Control Webpage and in the access example.
Importing DLL module into Excel or Access |
Using the COM DLL font encoder |
'Create a Visual Basic function to call the DLL from within your application Public Function EncPDF(DataToEncode As String, EcLevel As Integer, TotalColumns As Integer, TotalRows As Integer, Truncated As Integer, PDFMode As Integer, ApplyTilde As Integer) As String Dim PDF417FontEncoder As PDF417Lib.PDF Set PDF417FontEncoder = New PDF PDF417FontEncoder.FontEncode DataToEncode, EcLevel, TotalColumns, TotalRows, Truncated, PDFMode, ApplyTilde, EncPDF End Function
'Then, in your application, format the Output by calling the function, for example: 'In Visual Basic code: Output = EncPDF(DataToEncode, "0", "0", "0", "0", "0", "0") 'In an Excel formula, data pulled from cell A3: =EncPDF(A3,0,0,0,0,0,0) 'In a Microsoft Access control source formula: =EncPDF([table.field],0,0,0,0,0,0) 'Placing a tab function between fields in a Microsoft Access control source formula 'to encode more data in a single PDF-417 symbol. Be sure to set ApplyTilde to "1" also. =EncPDF(([Test Data.TextData] & "~009" & [Test Data.NumberData]),0,0,0,0,0,1)
'In Visual Basic you may also call the DLL directly, for example: Dim Output as String Dim PDF417FontEncoder As PDF417Lib.PDF Set PDF417FontEncoder = New PDF PDF417FontEncoder.FontEncode DataToEncode, 0, 0, 0, 0, 0, 0, Output 'The "Output" string contains the returned code
API and barcode functions for the COM and .NET DLLs |
FontEncode Function for COM DLL:
FontEncode (DataToEncode As String, EcLevel As Integer, TotalColumns As Integer, TotalRows As Integer, Truncated As Integer, PDFMode As Integer, ApplyTilde As Integer, Output as String) | The fields that use this function and
PDF417 font must accept returns and multiple lines. Enter zeros for
defaults in all integer fields, for example, in the COM DLL: PDF417(InputString,"0","0","0","0","0","0",OutputString) |
FontEncode Function for .NET DLL:
Variable=FontEncoder (DataToEncode As String, EcLevel As Integer, TotalColumns As Integer, TotalRows As Integer, Truncated As Boolean, PDFMode, ApplyTilde As Boolean) | Example: TextBox2.Text = NewBarcode.FontEncoder(DataToEncode, 0, 0, 0, False, PDF417Barcode.PDF417Modes.Text, True) |
How to use the .NET Control in .NET applications |
Step1: In your project, add a reference to the DLL and place the import statement in the declarations section of your project. For example:
Imports IDAutomation.Windows.Forms.PDF417Barcode Step2: The following code will obtain the data to encode and place it in the TextBox. This data, when printed with our PDF417 Font, will create a correct barcode:
Dim NewBarcode As PDF417Barcode = New PDF417Barcode()
TextBox2.Text = NewBarcode.FontEncoder(TextBox1.Text, 0, 0, 0, False, PDF417Barcode.PDF417Modes.Text, True)
For information about printing from the .NET Forms Control without using the font, please refer to our online Forms Control Manual.
For information about the ASP.NET Web Control, please refer to our online ASP.NET Web Control.
Barcoding with the PDF417 Java class font encoder |
Step1: First, you must have a Java 1.1 or greater virtual machine installed on the computer that is to format the data. Copy everything in the "Java Class Encoder" directory to the root directory of your computer's class path. If you don't know what the root is or need assistance in this area, consult the Java documentation or the company you obtained the Java virtual machine from.
Step2: After the directories are copied to the class root, the method to format data to the font can then be called from a method in a Java application as in this example:
import java.io.*; import IDautomationPDFE.*; class PDFTest { public static void main ( String [] args ) { String dataToEncode = "This is a test of the IDAutomation.com PDF417 Java Encoder."; PDF417Encoder pdfe=new PDF417Encoder(); System.out.println( pdfe.fontEncode(dataToEncode) ); } }
The data string returned by the FontEncode method will create a proper PDF417 symbol when displayed or printed with the PDF417 font. To install the font on your operating system, consult your OS documentation or follow our font installation procedures.
This section explains the main configuration parameters and methods of the PDF417 for Java encoder class.
For detailed information on PDF417, please review the PDF417 FAQ.
Distributing files for an application |
If you have purchased a Developer License for the PDF417 Font and Encoder, you may distribute the font files and applicable components with your application. In addition, if you purchase 3 Developer Licenses and have signed the source code license agreement, you may integrate the source code directly into your application, eliminating the need to distribute DLLs. The source code is available in VB, C++ and Java. Remember to have your application register the DLLs after they are copied to the system folder.
NOTE: Redistribution of our fonts and components requires a Developer license.
Windows Encoder COM Files (We recommend using an advanced installation application to distribute files for Windows) | ||
Purpose of File | File to Distribute | Notes |
Font File | IDAutomationPDF417n3.ttf | The PDF417 TrueType font. You may also distribute any other font files in the package as necessary. |
Encoder DLL | IDAutomationPDF417.dll | This is the encoder DLL that formats the PDF-417 font. It can be found in the system directory after installation. Because it was created with C++ ATL, it is small and has no dependencies. |
Windows Encoder .NET Files (We recommend using an advanced installation application to distribute files for Windows) | ||
Purpose of File | File to Distribute | Notes |
Font File | IDAutomationPDF417n3.ttf | The PDF417 TrueType font. You may also distribute any other font files in the package as necessary. |
Encoder DLL | idautomation.pdf417.dll | This is the encoder DLL and forms control. It requires the .NET Framework 1.0 or greater. |
Java Encoder Files for UNIX and Other Systems. | ||
Purpose of File | Files to Distribute | Notes |
PDF417 Java Class Library | PDF417Encoder.class | These files must exist in the IDautomationPDFE directory from the class path because IDautomationPDFE is the package name. |
Font File | <depends on OS> | Our PCL and PostScript fonts are commonly used on UNIX systems. |
Crystal Reports UFL Encoder Files (We recommend using an advanced installation application to distribute files for Windows) | ||
Purpose of File | File to Distribute | Notes |
Font File | IDAutomationPDF417n3.ttf | The PDF417 TrueType font. You may also distribute any other font files in the package as necessary. |
Encoder DLL | IDAutomationPDF417.dll | This is the encoder DLL that formats the PDF-417 font. It can be found in the system directory after installation. Because it was created with C++ ATL, it is small and has no dependencies. |
VB Runtime DLL | msvbvm60.dll | This runtime file already exists on most PCs and it is required for the Crystal UFL. It can be found in the system directory after installation. |
Crystal Runtime | U2lcom.dll | This is a crystal runtime file that is required to work with UFLs. |
Crystal UFL | CRUFLidautomationPDF.dll | The IDAutomation Crystal UFL. It can be found in the system directory after installation. |
NOTE: Redistribution of our fonts and components requires a Developer license.
PDF417 Issues and Solutions |
Some implementations of PostScript fonts can cause a small space to appear between rows in the symbol. The only way to overcome this issue is to make sure your printing application is not adding additional line feeds or in the case of PCL fonts, change the vertical motion index as indicated below. This space will not cause problems with scanners and the barcode will still be readable.
When using 12 or 14 point PCL fonts, an adjustment to the vertical motion index is not usually necessary. However, if you are using other sizes, you may need to adjust it to close the gap between rows. To set the vertical motion index, issue the command before printing with the PDF417 font. The code for the vertical motion index Command is escape "<Ec>" + "&" + lowercase L "l" + Number Index + Capital "C". Use the chart below to find the command for your font size. The number may be adjusted as necessary for your printer.
PCL Font Point Size | Vertical Motion Index Command to Use |
10 | <Ec> &l6.5C |
8 | <Ec> &l5.2C |
6 | <Ec> &l3.9C |
In the example above, the <Ec> represents the escape character for your software. In DOS Edit, Ec is represented by holding down the CTRL key and pressing the letter P, releasing both keys and then press the ESC key.
This issue may exist if you try to move the barcode to the right on the X axis using a programming language, such as Visual Basic. When using the printer.currentX specification to set the X axis, only the first line of the barcode would print in the new position and the remaining lines would print at zero (all the way to the left). This is because the printer.currentX specification is reset every time a return is performed. A return must be performed to print the font on the new line.
The best solution to this problem would be to find a command that could move the left margin so that returns will move the insertion point to the correct position. Since Visual Basic does not have a command like this, a small piece of code must be written to set the currentX for each line.
Step 1. Declare and initialize a variable with the desired X position.
Example: my_x = printer.currentX
Step 2. Replace the "Printer.Print OutputString" command with
something similar to the following:
For i = 1 To Len(Output) out1 = out1 & Mid(Output, i, 1) If Mid(Output, i, 1) = Chr(10) Then out1 = Replace(out1, Chr(10), "") out1 = Replace(out1, Chr(13), "") Printer.CurrentX = my_x Printer.Print out1 out1 = "" End If Next i
Use With Crystal Reports |
Int DataSegments=DAutomationFontEncoderPDF417Set(DataToEncode As String, EcLevel As Integer, TotalColumns As Integer, TotalRows As Integer, Truncated As Integer, PDFMode As Integer, ApplyTilde As Integer) |
PDF417 Font / Encoder Specifications |
Character Sets | GLI0 which encodes ASCII 0 to 255 of the ASCII character set. | |
Data Compaction Modes |
Text Compaction with all four sub modes supporting text and numbers. Byte Compaction mode supporting numbers, text and binary data. |
|
Reed Solomon Error Correction Levels | Selectable from 1 to 8 | |
Font Point Size: |
Approximate X dimensions for IDAutomationPDF417n3 |
|
12 | .048 cm | .018" |
10 | .038 cm | .015" |
8 | .032 cm | .012" |
6 | .024 cm | .009" |
4 | .016 cm | .006" |
Font Names | Description |
IDAutomationPDF417n3 | X to Y ratio =3: This is the standard PDF417 font. It has a X to Y ratio of 1:3 which is recommended by national and international standards. Y dimension = 3X |
IDAutomationPDF417n4 | X to Y ratio =4: This is a taller but thinner version of the PDF417 font for use with lower quality readers and special applications. It has an X dimension of .75 times the X dimension of PDF417c. It has a X to Y ratio of 1:4. This taller version also tends to work better with laser barcode scanners that can read PDF417. Increase the font size after switching to this ratio. Y dimension = 4X |
IDAutomationPDF417n5 | X to Y ratio =5: This is a taller and thinner version of the PDF417 font designed to be used for FEDEX label specifications and other applications that require an X to Y ratio of 5. The X dimension of this font is .010" or 10 MILS when printed at 11 points. More about FedEx and PDF-417 is located here. |
IDAutomationPDF417n2 | X to Y ratio =2: NOTE: Most scanners cannot dependably read this font. This is a shorter version of the PDF417 font for high quality imagers and scanners. It has an X dimension of 1.5 times the X dimension of PDF417c. It has an X to Y ratio of 1:2. You may use this font to reduce the symbol height if you are using high quality scanners in a clean environment. Decrease the font size after switching to this ratio. |
Font Names Prior to 7/2003: | New Font Name |
PDF417c2 | IDAutomationPDF417n2 |
PDF417c | IDAutomationPDF417n3 |
PDF417c4 | IDAutomationPDF417n4 |
PDF417c5 | IDAutomationPDF417n5 |
Product Links: [Barcode Fonts | Barcode Components | Barcode Label Software | Barcode Scanners] |
Copyright © 1999-2004 IDAutomation.com, Inc. IDAutomation and BizFonts are registered trademarks of IDAutomation.com, Inc. All other trademarks mentioned are the property of their respective owners.