Skip to main content
net8.0net8.0-windows7.0

Package Description

Published
Jul 10, 2024
2y ago
Total Downloads
14.7K
14,674

Install

dotnet add package Nerdbank.QRCodes --version 0.2.45-beta
ProductVersions
.NET
net8.0net8.0-windows7.0

README

Nerdbank.QRCodes

Features

  • Decode a QR code from a high quality render or a photo with a QR code somewhere in the image.
  • Encode data in a QR code (using the excellent QRCoder library) supporting several graphic formats (some Windows only) and even as ASCII art.

Usage

Create a QR code

There are lots of options for customizing QR codes including style, image in the center, colors, and output image format. Following is a basic example.

using QRCoder;

QREncoder encoder = new();
QRCodeGenerator generator = new();
QRCodeData data = generator.CreateQrCode("https://some.url", encoder.ECCLevel);
encoder.Encode(data, "some.png", traceSource: null);

Decode a QR code

Decoding a QR code is very straightforward.

using Bitmap bitmap = (Bitmap)Image.FromFile("some.jpg");
if (QRDecoder.TryDecode(bitmap, out string? data))
{
	Console.WriteLine(data);
}

Changes from Previous Version

v0.2.9-betav0.2.45-beta
Added Frameworks
net8.0net8.0-windows7.0
Removed Frameworks
net7.0net7.0-windows7.0
Added Dependencies
QRCoder(net8.0)
QRCoder(net8.0-windows7.0)
System.Drawing.Common(net8.0-windows7.0)
Removed Dependencies
QRCoder(net7.0)
QRCoder(net7.0-windows7.0)
ZXing.Net(net7.0-windows7.0)
System.Drawing.Common(net7.0-windows7.0)

Adoption Assessment

A verified publisher signal is available. Assess fit from the package's supported frameworks, license and dependency graph rather than popularity alone.

This version is marked prerelease. Validate its API and upgrade path before production use.Compatibility metadata lists 2 target frameworks; confirm the exact target used by your application.

Related Guides & Workflows

Learn how to evaluate, integrate, or audit this package in your .NET project.