Link Search Menu Expand Document

Create GS1 QR Code - C#

QR Code SDK sample in C# demonstrating ‘Create GS1 QR Code’

Program.cs
using System.Diagnostics;
using Bytescout.BarCode;

namespace GS1QRCode
{
    class Program
    {
        static void Main(string[] args)
        {
            // Create and activate QRCode instance
            using (QRCode barcode = new QRCode())
            {
                barcode.RegistrationName = "demo";
                barcode.RegistrationKey = "demo";

                // Enable generation of GS1 version of QR Code
                barcode.IsGS1 = true;

                // Set value that is formatted according to GS1 specification
                barcode.Value = "(01)07046261398572(17)130331(10)TEST5632(21)19067811811";

                // Save barcode image to file
                barcode.SaveImage("result.png");
            }

            // Open the image in default image viewer (for demo purpose)
            Process.Start("result.png");
        }
    }
}

Download Source Code (.zip)

Return to the previous page Explore QR Code SDK