blog-teaser

How to install the barKoder Barcode Scanner SDK plugin for Xamarin

 

Installation Guide for the barKoder Barcode Scanner SDK plugin for Xamarin

 

Here's a simple guide to using the barKoder SDK in your Xamarin project:

1. Add our Barkoder.Xamarin NuGet package from source "nuget.org"

 

2. Import the package into your project

   using Barkoder.Xamarin;

 

3. Grant permission to access the camera

To use the scanning features of the barKoder Barcode Scanner SDK, you need to grant camera permission. For Android devices, set the permission in the manifest from the package. For iOS devices, specify camera permission in the Info.plist file within your project:

  <key>NSCameraUsageDescription</key>
  <string>Camera permission</string>

 

4. Add BarkoderView

   private BarkoderView BkdView;

4.1 Android:

   BkdView = FindViewById<BarkoderView>(Resource.Id.barkoderView);

4.2 iOS:

BkdView = new BarkoderView();
var barkoderView = BkdView.View;
BkdView = new BarkoderView();
var BarkoderView = BkdView.View;
View.AddSubview(BarkoderView);
...
// TODO: Add constraints to BarkoderView

Both:

// In order to perform scanning, config property need to be set before
BkdView.Config = new BarkoderConfig("LICENSE_KEY");
BkdView.Config.DecoderConfig = new DecoderConfig();

 

6. Optional barKoder settings

"Please find the details below regarding the general settings of the barcode."

private void SetBarkoderSettings()
{
   // These are optional settings, otherwise default values will be used
   BkdView.Config.ImageResultEnabled = true;
   BkdView.Config.LocationInImageResultEnabled = true;
   BkdView.Config.RegionOfInterestVisible = true;
}

6.1 Barcode type iOS

private void SetActiveBarcodeTypes()
{
   /// There is option to set multiple active barcodes at once as array
   BkdView.Config.DecoderConfig.SetEnabledDecoders(
       new NSNumber[] {
           (int)DecoderType.Qr,
           (int)DecoderType.Ean13
       }
   );
   // or configure them one by one
   BkdView.Config.DecoderConfig.UpcA.Enabled = true;
}

6.1 Barcode type Android

private void SetActiveBarcodeTypes()
{
   /// There is option to set multiple active barcodes at once as array
   BkdView.Config.DecoderConfig.SetEnabledDecoders(
       new BKD.DecoderType[] {
           BKD.DecoderType.Qr,
           BKD.DecoderType.Ean13
       }
   );
   // or configure them one by one
   BkdView.Config.DecoderConfig.UpcA.Enabled = true;
}

 

7. "Please be advised that the scanning of the event is now available. You may proceed with the scanning process."

Upon entering the callback function MethodResultCallBackDecoderResultWithCompletion, the SDK has completed its initialization and is now ready for configuration or scanning.

 

7.1 Start scanning iOS

// Starting to scan
BkdView.StartScanning((result) =>
   // Fetching data
   // TODO: Getting results
);

7.1 Start scanning Android

// Starting to scan
BkdView.StartScanning(this);
// Fetching data
public void ScanningFinished(BKD.Result[] results, Bitmap resultImage)
{
   // TODO: Getting results
}

 

8. Licensing

The SDK will scan barcodes even without a valid license; however, all results will be randomly masked with (*) Asterisk characters. By using our software you are agreeing to our End User License Agreement. To obtain a valid license, one should create an account here and either get a trial license (to test the software out) or procure a production license that can be used within a live app. 

Latest Barcode Scanner SDK Articles,
Tutorials, and News

recentArticle

30+ Shocking UPC/EAN Code Statistics You Need to Know in 2026

UPC and EAN barcodes remain the backbone of global retail in 2026, powering billions of product scans every day. From supermarkets and warehouses to e-commerce and mobile shopping apps, these standardized barcodes enable fast checkouts, accurate inventory management, and seamless product identification. Discover 30+ surprising UPC/EAN statistics and fun facts that highlight why barcode technology continues to drive modern commerce.

Aug 07, 2026

Info

recentArticle

Why Coca-Cola, PepsiCo, and Red Bull Must Add QR Codes to Every Can by the End of 2027

By the end of 2027, many leading beverage brands, including Coca-Cola, PepsiCo, and Red Bull, are adopting QR codes and other 2D barcodes as part of the GS1 Sunrise 2027 initiative. These digital codes go beyond traditional barcodes by enabling faster retail operations while giving consumers instant access to product information, nutrition facts, recycling guidance, authenticity verification, promotions, and sustainability details with a simple smartphone scan.

Aug 04, 2026

Info