IRONSOFTWAREHOME
Read Barcodes
using IronBarCode;
using IronSoftware.Drawing;
using System.Drawing;
using System.IO;

// Reading a barcode is easy with IronBarcode

// From an image file (also supports JPEG, TIFF, BMP, etc.)
var resultFromFile = BarcodeReader.Read(@"file/barcode.png");

// From a Bitmap object
var resultFromBitMap = BarcodeReader.Read(new Bitmap("barcode.bmp"));

// From a IronSoftware.Drawing.AnyBitmap object
var resultFromAnyBitmap = BarcodeReader.Read(new AnyBitmap("barcode.bmp"));

// From an Image object
var resultFromImage = BarcodeReader.Read(Image.FromFile("barcode.jpg"));

// From a memory stream
MemoryStream imageMemoryStream = new MemoryStream();
var resultFromStream = BarcodeReader.Read(imageMemoryStream); // From a stream

// PDFs are more intricate and must be read using ReadPdf
var resultFromPdf = BarcodeReader.ReadPdf(@"file/mydocument.pdf");
Imports IronBarCode
Imports IronSoftware.Drawing
Imports System.Drawing
Imports System.IO

' Reading a barcode is easy with IronBarcode

' From an image file (also supports JPEG, TIFF, BMP, etc.)
Dim resultFromFile = BarcodeReader.Read("file/barcode.png")

' From a Bitmap object
Dim resultFromBitMap = BarcodeReader.Read(New Bitmap("barcode.bmp"))

' From a IronSoftware.Drawing.AnyBitmap object
Dim resultFromAnyBitmap = BarcodeReader.Read(New AnyBitmap("barcode.bmp"))

' From an Image object
Dim resultFromImage = BarcodeReader.Read(Image.FromFile("barcode.jpg"))

' From a memory stream
Dim imageMemoryStream As New MemoryStream()
Dim resultFromStream = BarcodeReader.Read(imageMemoryStream) ' From a stream

' PDFs are more intricate and must be read using ReadPdf
Dim resultFromPdf = BarcodeReader.ReadPdf("file/mydocument.pdf")
NuGet Download
PM > Install-Package BarCode
Read Barcodes

Read Barcodes

Reading barcodes using IronBarcode is effective and simple. IronBarcode supports various formats and has different methods for each situation. Whether you are a developer looking to read barcodes from images or a developer who needs to integrate a barcode application and manipulate the data, IronBarcode has you covered.

Barcode Reader in C#

With the BarcodeReader.Read method, developers can pass along the file path of any standard image formats such as png, jpg, and jpeg to quickly read the values within the file. Furthermore, the BarcodeReader.Read method works for Bitmap and AnyBitmap. This is ideal for applications that require manipulating or passing values using the standard Bitmap class. For developers needing a universally compatible Bitmap format across .NET 8, .NET Core, and .NET Framework, the AnyBitmap class offers a platform-agnostic solution. It enables seamless cross-compatibility, allowing you to write flexible code and pass variables without any obstructions.

The BarcodeReader class also has specific methods for reading barcodes from a PDF using ReadPdf to read barcodes from every image embedded in the PDF document, allowing developers to quickly obtain all barcodes.

Aside from the specified methods, the BarcodeReader methods allow developers to pass in the BarcodeReaderOptions for more fine-grain control and customization. This applies to every method within the BarcodeReader class, enabling options such as reading only the first barcode to save time, reading specific types of barcodes, and utilizing multithreading, among other customization options.

Explore our guide on reading barcodes from images in C#.
View on GitHub

Ready to Get Started?

Nuget Downloads 2,422,100Version:2026.9just released

Key in blue circle

Get your free 30-day Trial Key instantly.

Your trial license will be sent to your email address

No limitations. 100% unlocked. No credit card.

bullet_checkedNo credit card or account creation requiredNo limitations. 100% unlocked. No credit card.
  • Logo Aetna
  • Logo NASA
  • Logo GE
  • Logo Porsche
  • Logo USDA
  • Logo Qatar
Join Millions of Engineers who’ve tried IronPDF
Book your free Live Demo
Booking Badge

Trusted by Millions of Engineers Worldwide

Iron Software's customer logos
Get Your No-Obligation Consult
Complete the form below or email sales@ironsoftware.com
Your details will always be kept confidential.
Trusted by Millions of Engineers Worldwide
Iron Software's customer logos
Get your free 30-day Trial Key instantly.
No credit card or account creation required