ByteScout Barcode Reader SDK – C# – Decode Aztec

  • Home
  • /
  • Articles
  • /
  • ByteScout Barcode Reader SDK – C# – Decode Aztec

ByteScout Barcode Reader SDK – C# – Decode Aztec

Program.cs

using System;
using System.IO;

using Bytescout.BarCodeReader;

namespace ReadAztec
{
    class Program
    {
        const string ImageFile = "Aztec.png";

        static void Main()
        {
            Console.WriteLine("Reading barcode(s) from image {0}", Path.GetFullPath(ImageFile));

            Reader bc = new Reader();
            bc.RegistrationName = "demo";
			bc.RegistrationKey = "demo";

	    	// Set barcode type to find
            bc.BarcodeTypesToFind.Aztec = true;

            // Read barcodes
            FoundBarcode[] barcodes = bc.ReadFrom(ImageFile);

            foreach (FoundBarcode barcode in barcodes)
            {
                Console.WriteLine("Found barcode with type '{0}' and value '{1}'", barcode.Type, barcode.Value);
            }

            Console.WriteLine("Press any key to exit..");
            Console.ReadKey();
        }
    }
}


  Click here to get your Free Trial version of the SDK

prev
next