Skip to content

Latest commit

 

History

10 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

IronBarcode.Examples

Runnable C# examples for IronBarcode, a .NET barcode and QR code library that reads and generates Code 39/93/128, UPC-A/E, EAN-8/13, PDF417, Aztec, Data Matrix, QR, Micro QR, and 20+ other symbologies from images, PDFs, and streams.

Install

dotnet add package BarCode

Quickstart

using IronBarCode;

// Generate a barcode and save it
var barcode = BarcodeWriter.CreateBarcode("PKG-2026-88421", BarcodeEncoding.Code128);
barcode.ResizeTo(400, 100);
barcode.SaveAsPng("shipping-label.png");

// Read barcodes back from an image or PDF
var results = BarcodeReader.Read("shipping-label.png");
foreach (var result in results)
{
    Console.WriteLine($"{result.BarcodeType}: {result.Value}");
}

For QR codes, swap in QRCodeWriter.CreateQrCode("https://example.com", 300), which supports error correction levels and CreateQrCodeWithLogo for branded codes. To read barcodes from PDFs, use BarcodeReader.ReadPdf("document.pdf").

For production use, set a license key via License.LicenseKey = "YOUR-KEY". Without one, generated barcodes include a watermark.

What's in this repo

Each folder contains a self-contained .NET project you can open and run:

  • examples/ — focused snippets demonstrating individual features
  • get-started/ — minimal first projects covering installation and basic generation
  • how-to/ — task-oriented guides for specific barcode operations
  • quickstart/ — end-to-end project scaffolds
  • tutorials/ — longer walkthroughs combining multiple features

Common tasks covered

  • Generating linear barcodes: Code 39, Code 93, Code 128, EAN-8, EAN-13, UPC-A, UPC-E, ITF, Codabar, MSI Plessey
  • Generating 2D barcodes: QR, Micro QR, Aztec, Data Matrix, PDF417, MaxiCode
  • Reading barcodes from images, PDFs, bitmaps, and streams
  • Multi-barcode scanning with automatic detection
  • Image preprocessing: deskew, denoise, sharpen, threshold, contrast adjustment
  • Fluent styling: colors, margins, annotation text, resizing
  • QR code customization: error correction levels, embedded logos, color theming
  • Export formats: PNG, JPEG, BMP, TIFF, GIF, PDF, HTML, SVG
  • Reading with BarcodeReaderOptions for parallel multi-threaded scanning

Platform support

.NET 8, 7, 6, 5, .NET Core, .NET Standard, and .NET Framework. Windows, macOS, Linux, Docker, Azure, and AWS. See the installation docs for environment-specific notes.

Documentation and support

About

This repository is maintained by Iron Software. IronBarcode is a commercial library — see licensing for terms and trial details.

About

C# barcode and QR code library that reads and generates Code 39/93/128, EAN-8/13, UPC-A/E, PDF417, Aztec, Data Matrix, QR, Micro QR, and rMQR from images, PDFs, and streams. Runnable .NET examples for batch scanning, image preprocessing, styling with logos, error correction, and SVG export. ZXing alternative.

Topics

Resources

Stars

2 stars

Watchers

2 watching

Forks

Packages

Used by

Contributors

Languages