Getting Started with IronQR

IronQR is the QR Code Reading and Writing Library for .NET

IronQR is an Iron Software's QR Code reading and writing library. In addition to highly customizable QR Generation, it uses an advanced Machine Learning Model with Mobile, Desktop, and Cloud compatibility to detect QR Codes for reading.

Compatibility

IronQR has cross platform support compatibility with:

.NET Version Support:

  • C#, VB.NET, F#
  • .NET 7, 6, 5, and Core 3.1+
  • .NET Standard (2.0+)
  • .NET Framework (4.6.2+)

Operating Systems and Environments Support:

  • Windows (10+, Server 2016+)
  • Linux (Ubuntu, Debian, CentOS, etc.)
  • macOS (10+)
  • iOS (12+)
  • Android API 21+ (v5 "Lollipop")
  • Docker (Windows, Linux, Azure)
  • Azure (VPS, WebApp, Function)
  • AWS (EC2, Lambda)

.NET Project Types Support:

  • Web (Blazor & WebForms)
  • Mobile (Xamarin & MAUI)
  • Desktop (WPF & MAUI)
  • Console (App & Library)

Installation

IronQR Library

Installing the IronQR is quick and easy, please install the package like this:

Install-Package IronQR

Alternatively, download directly from the official IronQR NuGet website.

Once installed, you can get started by adding using IronQR; to the top of your C# code.

IronQR.Slim Library

Please note
IronQR.Slim contains both QR Generation and QR Reading (only basic reading).

The IronQR package contains the advanced custom Machine Learning Model and adapters to use it with IronQR.Slim. If you prefer to opt to use IronQR without the increased package size and improved accuracy of the ML model, you can also use IronQR.Slim alone.

This will have no effect on generating/writing QR Codes but reading will not utilize the advanced detection model. You can use the following command to install just the basic Slim version.

Install-Package IronQR.Slim

Code Examples

Generate QR Code Example

:path=/static-assets/qr/content-code-examples/get-started/get-started-1.cs
using IronQr;
using IronSoftware.Drawing;

// Create a QR Code object
QrCode myQr = QrWriter.Write("hello world");

// Save QR Code as a Bitmap
AnyBitmap qrImage = myQr.Save();

// Save QR Code Bitmap as File
qrImage.SaveAs("qr.png");
Imports IronQr
Imports IronSoftware.Drawing

' Create a QR Code object
Private myQr As QrCode = QrWriter.Write("hello world")

' Save QR Code as a Bitmap
Private qrImage As AnyBitmap = myQr.Save()

' Save QR Code Bitmap as File
qrImage.SaveAs("qr.png")
VB   C#

Read QR Code Example

:path=/static-assets/qr/content-code-examples/get-started/get-started-2.cs
using IronQr;
using IronSoftware.Drawing;
using System.Collections.Generic;

// Open the asset to read a QR Code from
var inputBmp = AnyBitmap.FromFile("IMAGE_TO_READ.png");

// Load the asset into QrImageInput
QrImageInput imageInput = new QrImageInput(inputBmp);

// Create a QR Reader object
QrReader reader = new QrReader();

// Read the Input an get all embedded QR Codes
IEnumerable<QrResult> results = reader.Read(imageInput);
Imports IronQr
Imports IronSoftware.Drawing
Imports System.Collections.Generic

' Open the asset to read a QR Code from
Private inputBmp = AnyBitmap.FromFile("IMAGE_TO_READ.png")

' Load the asset into QrImageInput
Private imageInput As New QrImageInput(inputBmp)

' Create a QR Reader object
Private reader As New QrReader()

' Read the Input an get all embedded QR Codes
Private results As IEnumerable(Of QrResult) = reader.Read(imageInput)
VB   C#

Support Available

Information

For more information about Iron Software please visit our website: https://ironsoftware.com/

Support from Iron Software

For general support and technical inquiries, please email us at: mailto:support@ironsoftware.com