Our Customers
Contact Us Email: support@barcodelib.com
Home > Barcode .NET Reader DLL > How to Read Barcode in Visual C# > Using PDF-417 C# barcode reading library to read PDF-417 barcode images
Download Barcode Reader for .NET Trial

How to Use C# PDF417 Barcode Reader Library

Tutorial for PDF-417 barcode scanning & reading using Visual C#.NET
  • Integrate entirely in Visual Studio .NET projects, like .NET Windows, ASP.NET Web, .NET Class Library
  • Support multi-page TIFF PDF417 barcode images reading in .NET applications
  • Read & recognise all PDF-417 barcode images data from a single image file with one line C# code
  • Provide free C# sample code for .NET PDF-417 2d barcode reading & decoding
  • Capable of reading linear barcodes in C# as well, including Code 39, Code 128, EAN-8, EAN-13, UPC-A, UPC-E, etc
  • Entitle to redistribute C#.NET barcode reader with a purchased Windows Application or Server License
How to Integrate C# PDF-417 Barcode Reading Library
  1. You may firstly download free C# Barcode Reader SDK for .NET trial version.
  2. And add "BarcodeLib.BarcodeReader.dll" to your Visual C# .NET project reference.
How to Use Visual C# Code to Read PDF-417 2D Barcode Image
After you integrate C#.NET Barcode Decoder to your application reference you can the following C# demo code to scan PDF-417 barcode.
     string[] results = BarcodeReader.read("c:/pdf417-csharp.gif", BarcodeReader.PDF417);
Using this C# demo code, all the barcode images in file "pdf417-csharp.gif" will be scanned.
How to Use Special Functions to Read C# PDF-417 2D Barcode Image
BarcodeLib.com C#.NET Barcode Decoder can be used to recognize PDF-417 barcode images for .NET, ASP.NET Web, Windows, C#, VB.NET Class Library applications. To fulfill different requirements, we design some special barcode recognition methods.

1. Scan the Maximum One PDF-417 Barcode from a Large Size Image Source

To do so, you need to adjust the property maxOneBarcodePerPage to "true".
  1. In this case, our PDF-417 C#.NET Barcode Decoder Library will stop scanning the barcode when it detects one PDF-417 barcode.
  2. If not "true", our PDF-417 C#.NET Barcode Decoder Library will use total 5 algorithms and each will read the whole source file from 4 directions.

2. Scan a Specific Part of the Source Image File Where the PDF-417 Barcode Is Located

If your PDF-417 barcode image is always at specific area on the image file, you may set PDF-417 .NET Barcode Reader SDK to scan that area only. And this saves a lot of reading time, CPU and memory usage.
  1. As for the specific are, you can just demonstrate the left top point and right bottom point of the area (the point X, Y values are expressed in percentage of the whole image, so image most left top point is (0%, 0%), and most right bottom point is (100%, 100%)).
Please use the following example to scan your PDF-417 barcocde on source image specific area, and we take top 20% and bottom 20% of a sample image file "pdf417-csharp.gif" as an example.
     OptimizeSetting setting = new OptimizeSetting();

setting.setMaxOneBarcodePerPage(true);

ScanArea top20 = new ScanArea(new PointF(0.0F, 0.0F), new PointF(100.0F, 20.0F));

ScanArea bottom20 = new ScanArea(new PointF(0.0F, 80.0F), new PointF(100.0F, 100.0F));

List<ScanArea> areas = new List<ScanArea>();
areas.Add(top20);
areas.Add(bottom20);

setting.setAreas(areas);

string[] results = BarcodeReader.read("c:/pdf417-csharp.gif", BarcodeReader.PDF417, setting);
How to Use Visual C# Code to Decode Other Linear & 2D Barcodes
Scan 1D Barcode Images:
Scan 2D Barcode Images:
How to Recognise Linear & 2D Barcodes for Related .NET Programs