Online Guide

How to Use BC.NetBarcodeReader.All Library
Scan, read, and decode 2d & 1d barcodes from images including Png, Jpg, Jpeg, Tiff, Bmp, and Gif.

Guide Overview

BC.NetBarcodeReader.All library is widely used to read and recognize barcodes from images in your .NET projects. Here we will show you how to read a barcode from image c# and how to read a barcode from image vb.net. Within simple steps, you can add robust barcode reading functionality into your .NET applications. Please firstly download and get the free trial of .NET barcode reader library (BC.NetBarcodeReaderTrial.All.dll). And the only thing for the integration of our .NET barcode reader library is to add it to your .NET project reference.

BC.NetBarcodeReader.All

We take the Console Application as an example of how to use BC.NetBarcodeReader.All library to scan and read 1D & 2D barcodes from images. Our .NET barcode reader library supports QR Code, Data Matrix, PDF417, Code 128, Code 39, EAN-13, EAN-8, UPC-A, UPC-E, and Interleaved 2 of 5 barcode symbologies. For ease of use, below are simple code examples for how to read a barcode in C# and VB.NET programs. Moreover, a demo project is included in the free trial package of our .NET barcode reader library. You can download a free trial to see more.


1. You can scan and read a single barcode type from an image using BC.NetBarcodeReader.All library.

How to Read a Barcode from Image in C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BC.NetBarcodeReaderTrial.All;

namespace BC.NetBarcodeReaderDemo
{
    class Program
    {
        static void Main(string[] args)
        {
            ReadOneBarcodeTypefromImage();
        }

        public static void ReadOneBarcodeTypefromImage()
        {
            string[] data = NetBarcodeReader.Recognize("Qrcode.png", NetBarcodeReader.Qrcode);

            /*string[] data1 = NetBarcodeReader.Recognize("F:/Code128.jpg", NetBarcodeReader.Code128);
            string[] data2 = NetBarcodeReader.Recognize("F:/Code39.jpeg", NetBarcodeReader.Code39);
            string[] data3 = NetBarcodeReader.Recognize("F:/Ean13.gif", NetBarcodeReader.Ean13);
            string[] data4 = NetBarcodeReader.Recognize("F:/Ean8.gif", NetBarcodeReader.Ean8);
            string[] data5 = NetBarcodeReader.Recognize("F:/Interleaved25.bmp", NetBarcodeReader.Interleaved25);
            string[] data6 = NetBarcodeReader.Recognize("F:/Upca.bmp", NetBarcodeReader.Upca);
            string[] data7 = NetBarcodeReader.Recognize("F:/Upce.tif", NetBarcodeReader.Upce);
            string[] data8 = NetBarcodeReader.Recognize("F:/Pdf417.tif", NetBarcodeReader.Pdf417);
            string[] data9 = NetBarcodeReader.Recognize("F:/Datamatrix.png", NetBarcodeReader.Datamatrix);*/

            foreach (string result in data)
            {
                Console.WriteLine(result);
            }
            Console.ReadKey();
        }
    }
}

How to Read a Barcode from Image in VB.NET

Imports System
Imports System.Collections.Generic
Imports System.Linq
Imports System.Text
Imports BC.NetBarcodeReaderTrial.All

Module BCNetBarcodeReaderDemo  

    Sub Main()
        ReadOneBarcodeTypefromImage()
    End Sub

    Public Sub ReadOneBarcodeTypefromImage()
        Dim data As String() = NetBarcodeReader.Recognize("Qrcode.png", NetBarcodeReader.Qrcode)

        'Dim data1 As String() = NetBarcodeReader.Recognize("F:/Code128.jpg", NetBarcodeReader.Code128)
        'Dim data2 As String() = NetBarcodeReader.Recognize("F:/Code39.jpeg", NetBarcodeReader.Code39)
        'Dim data3 As String() = NetBarcodeReader.Recognize("F:/Ean13.gif", NetBarcodeReader.Ean13)
        'Dim data4 As String() = NetBarcodeReader.Recognize("F:/Ean8.gif", NetBarcodeReader.Ean8)
        'Dim data5 As String() = NetBarcodeReader.Recognize("F:/Interleaved25.bmp", NetBarcodeReader.Interleaved25)
        'Dim data6 As String() = NetBarcodeReader.Recognize("F:/Upca.bmp", NetBarcodeReader.Upca)
        'Dim data7 As String() = NetBarcodeReader.Recognize("F:/Upce.tif", NetBarcodeReader.Upce)
        'Dim data8 As String() = NetBarcodeReader.Recognize("F:/Pdf417.tif", NetBarcodeReader.Pdf417)
        'Dim data9 As String() = NetBarcodeReader.Recognize("F:/Datamatrix.png", NetBarcodeReader.Datamatrix)

        For Each result As String In data
            Console.WriteLine(result)
        Next

        Console.ReadKey()
    End Sub

End Module

2. You can scan and read more than one barcode types from an image using BC.NetBarcodeReader.All library.

How to in C# Read Barccodes from Image
(More than One Type)

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BC.NetBarcodeReaderTrial.All;

namespace BC.NetBarcodeReaderDemo
{
    class Program
    {
        static void Main(string[] args)
        {
            ReadMultipleBarcodeTypesfromImage();
        }

        public static void ReadMultipleBarcodeTypesfromImage()
        {
            string[] data = NetBarcodeReader.Recognize("Multiple.jpg", NetBarcodeReader.Qrcode);
            string[] data1 = NetBarcodeReader.Recognize("Multiple.jpg", NetBarcodeReader.Code128);

            foreach (string result in data)
            {
                Console.WriteLine(result);
            }
            foreach (string result1 in data1)
            {
                Console.WriteLine(result1);
            }
            Console.ReadKey();
        }
    }
}

How to in VB.NET Read Barccodes from Image (More than One Type)

Imports System
Imports System.Collections.Generic
Imports System.Linq
Imports System.Text
Imports BC.NetBarcodeReaderTrial.All

Module BCNetBarcodeReaderDemo  

        Sub Main()        
            ReadMultipleBarcodeTypesfromImage()    
        End Sub

        Public Sub ReadMultipleBarcodeTypesfromImage()
            Dim data As String() = NetBarcodeReader.Recognize("Multiple.jpg", NetBarcodeReader.Qrcode)
            Dim data1 As String() = NetBarcodeReader.Recognize("Multiple.jpg", NetBarcodeReader.Code128)

            For Each result As String In data
                Console.WriteLine(result)
            Next

            For Each result1 As String In data1
                Console.WriteLine(result1)
            Next

            Console.ReadKey()
        End Sub

End Module

Besides reading barcodes from images, we also provide barcode recognition solution for PDF document. If you are also interested in this, please see our product BC.NetPdfBarcodeReader.All and its online guide.


Please contact us if you have any questions about using our .NET barcode reader sdk. And we appreciate your feedback on how do you find our .NET barcode reader sdk. Do you use c# barcode reader, c# barcode reader library, c# barcode image reader, .net barcode reader, barcode reader online, barcode reader c#, barcode reader sdk asp.net, c# barcode reader from image, barcode reader in c#, net barcode reader, barcode reader in vb.net, net barcode reader library, best barcode reader sdk, barcode reader asp net c#, .net barcode reader sdk, barcode reader sdk for net, vb.net barcode reader library, multiple barcode reader online, vb.net barcode reader and scanner, barcode reader sdk free, online barcode reader, or asp.net barcode reader to find it?