126 ratings
  • 1
  • 2
  • 3
  • 4
  • 5
5 star 38
4 star 40
3 star 22
2 star 18
1 star 8
Compatible with
  • Windows
  • iOS
  • Android

ZXing.Net.Mobile 2.0.4.17

Redth

ZXing.Net.Mobile is a C#/.NET Barcode Scanning Library

ZXing.Net.Mobile is a C#/.NET library based on the open source Barcode Library: ZXing (Zebra Crossing), using the ZXing.Net Port. It works with Xamarin.iOS, Xamarin.Android, Windows Phone (Silverlight) and Windows Universal. The goal of ZXing.Net.Mobile is to make scanning barcodes as effortless and painless as possible in your own applications!

Features

  • Xamarin.iOS
  • Xamarin.Android
  • Windows Phone (Silverlight)
  • Windows Universal (UAP 10)
  • Simple API - Scan in as little as 2 lines of code!
  • Scanner as a View - UIView (iOS) / Fragment (Android) / Control (WP)
  • Custom Overlays
  • AVCaptureSession Detection optional support for iOS

Release Notes

2.0.4.17

  • Many improvements to the core scanning engine to help with Forms support (separate component)
  • Bugfixes, performance enhancements

1.5.4.0

  • Added WP81 explicitly
  • Added PCL folder

1.5.3.0

  • Android: Bugfixes for cancelling continuous scanning and exclusive camera lock
  • iOS: Bugfixes for concurrency issues

1.5.1.0

  • Added BarcodeWriter's and bitmap renderers to each platform implementation

1.5.0.0

  • Now PCL compatible
  • Windows Phone: More feature parity
  • Various bugfixes, improvements on all platforms
Write a Review

52 reviews

Asanka Mawilmada

Dear Developer(s)

This is a grate component and was extremely easy to include in Xamarin forms/ios. we love the new customization options too. Good job with that.

But unfortunately recently we found out that it has trouble reading the bar-code under different lighting conditions, even after enabling AV capture engine it fails to read under most cases. if you can shed some light on how to resolve this issue would be much appreciated.

Thank you Asanka

Posted on: March 23 / Version: 2.0.4.17
ANTONIO CANDELA BRU rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Zxing Scanner 2.0.4.17 crash with Galaxy Ace 2 when try to open scanner and force to quit. This happens on my app and also with sample downloaded. Please solve this bug.

Thanks.

Posted on: February 24 / Version: 2.0.4.17
anjibabu

Hi All,

It's worked fine for small barcodes.If we scan larger(more than 10 chars/digits) it will take much time to scan that one.please help me. Thanks in Advance...

Posted on: February 6 / Version: 2.0.4.17
Patrick Kelly rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Just needed it for Code39 scans. Doesn't work on IPhone 6 or Samsung Galaxy S4 or IPad with any type of consistency. Used to work about 60% of the time on the Samsung Galaxy, but after a recent update it fails to scan over 95% of the time. If you need it to Scan UPC it works great, just doesn't meet my needs at all.

Posted on: December 10, 2015 / Version: 1.5.4.0
Leo Argyropoulos rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Works beautifully in my iOS 9 app on an iPhone 6. Seriously, two lines of code to launch the scanner?! Tremendous!

Posted on: December 4, 2015 / Version: 1.5.4.0
Björn Bentmar rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

This would be a 5 star review if the scanner could scan Vertically and not only horizontally.

Posted on: November 25, 2015 / Version: 1.5.4.0
Saeid Babaei

I download zxing.net.mobile-1.5.4.0 , i run my app in visual studio and call "scanner.scancontinuously(opt,HandleScanResult)" in an activity and the scanner works good and then i finish the Scan. but when i call "var result=await scanner.Scan()" in OTHER activity, after that, the scanner scan continuously again. whats the problem?

Sorry for bad english!!!

Posted on: November 23, 2015 / Version: 1.5.4.0
Hani Gamini

Hi,

I download zxing.net.mobile-1.5.4.0 , when i run Sample.Android in visual studio i got this errors : 1 ) Severity Code Description Project File Line Error CS0012 The type 'Object' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

2) Severity Code Description Project File Line Error package android.support.v4.content.Loader does not exist android.support.v4.content.Loader.OnLoadCanceledListener ....

Posted on: November 15, 2015 / Version: 1.5.4.0
Volkan Akkus rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Need some attention; upgrade nuget package, complete cancel functionality.

Posted on: November 2, 2015 / Version: 1.5.1.0
Marius Van Wyk rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Good work. I just have one problem. How do I cancel/Stop the continious scan ?

I have 2 buttons: button.Click += async delegate { scanner.TopText = "Hold the camera up to the barcode\nAbout 6 inches away"; scanner.BottomText = "Wait for the barcode to automatically scan!";

            var result = await scanner.Scan();
            HandleScanResult(result);

        };

        button2.Click += delegate
        {
            var opt = new MobileBarcodeScanningOptions();
            opt.DelayBetweenContinuousScans = 3000;
            scanner.TopText = "Hold the camera up to the barcode\nAbout 6 inches away";
            scanner.BottomText = "Wait for the barcode to automatically scan!";
            scanner.ScanContinuously(opt, HandleScanResultContinuous);

}

Both work fine, on the single click I have a dialogue for users to enter additional data, and it works fine. On the continious scan, if i go back the app exist, it dont just cancel ?

Posted on: October 14, 2015 / Version: 1.5.1.0
chandran rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Hi !...

I am trying to use your component in Windows Tablet 8.1. But I could not get succeeded. I am always getting the run time error as "An exception of type System.NotSupportedException occured in ZXingNetMobile.DLL but was not handled in user code. Use the platform specific implementation instead". I tried to develop this in platform specific solution but same error. How can I solve this problem or do you have any updated version of this component which supports for Windows tablet 8.1.

Awaiting for your response.

Posted on: October 5, 2015 / Version: 1.5.1.0
Aleksander Rurarz rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

I can't add libs to windows phone 8.1 xamarin project. It says that these libs are targeted for windows phone 8.0 only. Is there any solution for that?

Posted on: September 3, 2015 / Version: 1.5.1.0
Ludovico rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

How to stop ScanContinuously? If i try scanner.Cancel() the app crash :(

Help please!!

Posted on: September 1, 2015 / Version: 1.5.1.0
Severin Brinch Joergensen rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Not working in iOS 9.0 :-(

It seems to think it is running on the simulator: Debug: "No input - this won't work on the simulator, try a physical device" "Capture Session FAILED”

Please fix :-)

Posted on: July 31, 2015 / Version: 1.5.0.0
Fernando Arreguin rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

HELP!

This component doesn't work for iOS 9.0 Preview !!

Posted on: July 14, 2015 / Version: 1.4.7.2
srikanth n

On an iPod Device with iOS 7.0.6, App is getting crashed when barcode scanner kept opened for longer time(1min or more) following is the code:

MobileBardcodeScanner scanner = new MobileBardcodeScanner (); var result = await scanner.Scan(true); if(result!=null) Console.WriteLine("BarCode: "+result.Text);

In scan Overload Method, passing parameter "true", same thing working fine on a device with iOS 8.1

Posted on: June 22, 2015 / Version: 1.4.7.2
Ramesh V P rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Sometimes it is not scanning properly in IOS.Please fix it.

Posted on: June 8, 2015 / Version: 1.4.7.2
Fabio Cabella rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

This component is exactly what I need to start my first Mobile App.

Thanks!

Posted on: May 10, 2015 / Version: 1.4.7.2
Ewout Guillemyn rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Works great.

Posted on: April 30, 2015 / Version: 1.4.7.2
Antoniou Loukas rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Works great, Easy to implement. One great addition would to be to be able to scan in burst mode. If you could scan without the controller been dismissed every time it would get five stars.

Posted on: April 24, 2015 / Version: 1.4.7.2
David Parízek

I have the same issue as Tim A. and Phillipp Lulay.. Has anyone fixed it? Thank you

/Users/David/Projects/SmartPub 32bit copy/SmartPub/MTOUCHTASK: Error MT2002: Failed to resolve "System.Void CoreGraphics.CGBitmapContext::.ctor(System.IntPtr,System.nint,System.nint,System.nint,System.nint,CoreGraphics.CGColorSpace,CoreGraphics.CGImageAlphaInfo)" reference from "Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065" (MT2002) (SmartPub)

Posted on: January 30, 2015 / Version: 1.4.7.2
Tim A.

I have the same problem as Philipp Lulay below.

Running XS 5.7, X.iOS 8.6, I cannot deploy to device. Only to emulator.

Posted on: January 8, 2015 / Version: 1.4.7
Philipp Lulay rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Up to now it worked well. With new Xamarin.ios 8.6 it does not work anymore.

Xamarin.iOS Unified API Sample does not work either.

Failed to resolve "System.Void CoreGraphics.CGBitmapContext::.ctor(System.IntPtr,System.Int32,System.Int32,System.Int32, System.Int32,CoreGraphics.CGColorSpace,CoreGraphics.CGImageAlphaInfo)" reference from "Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065"

Posted on: December 30, 2014 / Version: 1.4.7
dinesh rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

I'm getting this below error while integrating in Xamarin.iOS. I'm using Xamarin studio 5.1 and Xcode 5.0.

Error MT2002: Failed to resolve "MonoTouch.Foundation.NSString MonoTouch.AVFoundation.AVCaptureSession::get_Preset1920x1080()" reference from "monotouch, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065" (MT2002)

Posted on: December 11, 2014 / Version: 1.4.7
Zaki Merchant

Still facing this issue which is mentioned as being fixed in 1.4.4, it must not be handling the iOS version properly as it works on apps built on iOS8 but not on those built on iOS7

iOS: Fixed cosmetic issue where loading black screen would be raised in portrait

Posted on: November 14, 2014 / Version: 1.4.7
Jim Dunham rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Great job! Updated from 1.4.2 to 1.4.7 recently. Much improved scanning capabilities.

Posted on: October 2, 2014 / Version: 1.4.7
Eric BREITENSTEIN

Hello,

I develop an application special Vending Machine for maintenance. I use a simple barcode code39 on maintenance's document.

I tested ZXing.Net.Mobile 1.4.6 on Samsung Phone S4 Mini I9195, no issue with this phone.

But With Sony XPERIA M2 (D2303) with last rom update KitKat 4.4.2. No autofocus to scan a simple barcode CODE39, it's always blur.

Do you have a fix to resolve this issue on developp branch ?

Thank you

Posted on: September 15, 2014 / Version: 1.4.6
Przemyslaw Kubarek

The same problem as shanminxu - is anybody who can help ?

Posted on: September 5, 2014 / Version: 1.4.6
shanminxu rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

on simulator compiles ok, when deploy to iOS devices, debug or release, got this error:

error MT2002: Failed to resolve "MonoTouch.Foundation.NSString MonoTouch.AVFoundation.AVCaptureSession::get_Preset1920x1080()" reference from "monotouch, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065”

I checked the mono reference, it does not have preset 1920x1080, don't know why.

Any help is really appreciated, Thanks!

Posted on: August 11, 2014 / Version: 1.4.6
Zhu David

Hi, is there anyone could provide the complete sample code to generate QR code and display in content page, thx!

Posted on: July 29, 2014 / Version: 1.4.5
Mathew Twardowski rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Works okay. Would be nice if the heuristics on the QR code accounted for some damage on the 3 corner marks on the QR tags, but repairing these marks with a pen works okay. If we needed more data protection we'd have used RFID tags.

Also, don't know if it's how I implemented it, but I did see it on the iOS sample, but when launching the scanner on an iPad in landscape orientation, the loading overlay doesn't resize to the screen in that orientation. I used a pure black view to mask the screen so it doesn't look as bad, and hide it when scanning complete.

Posted on: May 16, 2014 / Version: 1.4.4
John Rowse rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

I am trying the sample app on android 4.0.1 (samasung galaxy tab 2), and the only barcodes I can scan are ones I have brought up on google image, blown up in high resolution. Standard barcodes you get on the back of a book or tin of beans, do not work. Any reason why I could be having issue? Before you ask, I have tried in good light, and slowly adjusted the distance to get the optimal focus and range. A supermarket app I have installed, that uses the same sort of process, scans without issue.

Posted on: April 10, 2014 / Version: 1.4.4
Paul Auman rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Great Job! Here is an example of generating QR code(s) with ZXing and MT

[code]

using ZXing; using ZXing.Mobile; using ZXing.QrCode; using ZXing.Common;

….

QRCodeWriter writer = new QRCodeWriter(); ZXing.Common.BitMatrix matrix;

int size = 120; matrix = writer.encode("http://aumansoftware.com;", BarcodeFormat.QR_CODE, size, size, null);

SizeF qrcCodeSize = new SizeF(size,size);

UIGraphics.BeginImageContext(qrcCodeSize);

using (CGContext cont = UIGraphics.GetCurrentContext()) { cont.SetLineWidth(1); cont.SetFillColor(UIColor.White.CGColor); cont.AddRect(new RectangleF(0,0,qrcCodeSize.Width,qrcCodeSize.Height)); cont.DrawPath(CGPathDrawingMode.Fill);

                    cont.SetFillColor(UIColor.Black.CGColor);


                    for (int y = 0; y < matrix.Height; y++)
                    {
                        for (int x = 0; x < matrix.Width; x++)
                        {

                            if(matrix[x,y]) cont.AddRect(new RectangleF(x,y,1,1));


                        }

                    }


                    cont.DrawPath(CGPathDrawingMode.Fill);

                    UIImage qrcImage = UIGraphics.GetImageFromCurrentImageContext();

// show image in imageview UIImageView qrcImageView defined earlier... qrcImageView.Image = qrcImage; qrcImageView.SetNeedsDisplay();

}//end using cont

UIGraphics.EndImageContext();

[/code]

Cheers,

Paul Auman Auman Software, LLC

Posted on: April 8, 2014 / Version: 1.3.5
George Polites rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

I have been trying for over two days to make it recognize EAN 13 barcodes with different devices. I started with an iPod touch (4th Gen) and when I saw that it does not recognize I tried with iPad 3 and then iPhone 4s under different light conditions (flash no flash etc.) I have a similar project with Objective-C and ZBar and I had no problem even with the terrible camera of the iPod touch. In my trials I got some scans but I had to move the device trying for the best shot for several minutes each time. Tried different options but no luck.

Posted on: April 8, 2014 / Version: 1.3.5
Rogier Rietdijk rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

The scanner became slow after 4/5 times use.

Posted on: April 8, 2014 / Version: 1.3.7
Joshua Krebs rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

I, much like Rogier Rietdijk am experiencing the same issue with the scanner becoming slow after 4/5 times use. It would be great if we could figure out what is causing this... it seems to only affect iOS. The Android version works GREAT!

Posted on: April 8, 2014 / Version: 1.3.7
Matt Cuda rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

This is a good component for everyday scanning where scan time is not that crucial, but it does not compare to products such as RedLaser and Scandit. My big request right now is that the author spend some time optimizing this product to take it from good to great!

Update: I am infrequently running into an issue where the camera does not close propertly or does not open properly, but the end result is that the aperature image on the camera stays shut and will not open up so the user can scan.

Posted on: April 8, 2014 / Version: 1.3.3
Rupesh Bhavsar

I have integrated above barcode scanner to my solution in Xamarin. There are no exceptions,but when iam going to scan any code using the solution,iam not getting any result,it keeps on scanning all the time,until i stops. What could be the problem? Can any one help.

Posted on: April 8, 2014 / Version: 1.4.3
Pavel Szypka

Same problem for me as Rupesh Bhavsar. I am just stuck at scanning but with no result. (tested on Huawei G510, G300 and Sony Xperia Pro mini)

Posted on: April 8, 2014 / Version: 1.4.3
shaghayegh hadadi

this android sample can't build .it makes error !

error is: cannot find all required by the 'async' modifier.

Posted on: April 8, 2014 / Version: 1.4.3
Magdy Sharkawy rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Just compiled the sample application in V 1.4.0, unfortunately the camera starts with 90 degree rotation. Please solve this issue or advice how to solve it.

Posted on: April 8, 2014 / Version: 1.4.0
ding ling rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Just return one result that many barcode in the scan screen. Cloud it return more result?and the read speed is slower.

Posted on: April 8, 2014 / Version: 1.4.0
Robert rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Wow! I must say, I am very impressed with how simple this is. This doesn't have a bunch of .dll references or 1300+ lines of code.

Posted on: April 8, 2014 / Version: 1.4.0
Craig Schulte rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Ok, it took me awhile to get this working on Android, but once I did it was great. Documentation and examples could be improved slightly to make 1st time implementation easier, otherwise lazy developers like myself will just assume it's broken and move on. 2 things to note: Android requires you to provide a Context in the constructor, and you also must include the camera permission (duh). Once I found the demo project it helped a lot, but I didn't notice it at first.

Haven't tested it on many devices yet - so far just the Galaxy S3.

Overall, big time saver, thanks.

Posted on: April 8, 2014 / Version: 1.3.3
Vitor Barbosa rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Good component, but as Craig said in his review, on Android you must provide a context to the MobileBarcodeScanner constructor, otherwise it won't work.

Another gripe of mine is that the whole project is downloaded when you add this component to a project, which leaves you with around 8MB of source code. I added that folder to my svn ignore list, but other components don't seem to require this.

Posted on: April 8, 2014 / Version: 1.3.3
Alexey Bogdanov rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Gives a "Error MT2002: Failed to resolve "System.Boolean System.Type::op_Equality(System.Type,System.Type)" reference from "mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" (MT2002)" error.

Posted on: April 8, 2014 / Version: 1.3.3
Le-roy Staines

I also get the 'System.boolean' error! Help!

EDIT: Downloaded the source from https://github.com/Redth/ZXing.Net.Mobile and recompiled the DLL's and it worked :)

Posted on: April 8, 2014 / Version: 1.3.3
Michael Rutherford rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Very nice component - but it's still a beta product.

I was able to swap out the RedLaser component with a couple of hours work (total) - I added the component, changed a few references, tweaked some code, dropped the Redlaser files and modified TFS appropriately. I set it to scan only UPC and EAN codes and it performed very well. My project is an iOS presales app for beer, wine and soda distributors.

I bumped into an issue that caused me to remove the component (temporarily). When I called up the scan overlay, and was put into background mode, I called the Cancel() method on the scanner. But, when my app re-entered the foreground, the camera wouldn't re-open (probably a straightforward fix).

Also, the documentation could do with a refresh - although the sample project for iOS was very useful.

I'm really looking forward to the next update :)

Posted on: April 8, 2014 / Version: 1.3.3
Justin Moses rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

I'm a big fan of this component. I love the customization options now, my only concern at this point (in IOS), is that I have no way to open a new window immediately upon capturing a result without going into the rootviewcontroller's ViewDidAppear method.. and using some kind of internal variable. Right now there is no event exposed that tells me when the Viewcontroller that hosts the UIView for the scanner.. has been dismissed.

Posted on: July 17, 2013 / Version: 1.3.5
Benjamin Soulier rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Works great now, thanks for the update!

Posted on: June 19, 2013 / Version: 1.3.3
Justin Moses rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Just wanted to say that I use this component pretty frequently, and it works great. : )

Posted on: June 18, 2013 / Version: 1.3.2
Benjamin Soulier rates this with
  • 1
  • 2
  • 3
  • 4
  • 5

Impossible to use on Xamarin.IOS, giving a "Error MT2002: Failed to resolve "System.Boolean System.Type::op_Equality(System.Type,System.Type)" reference from "mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" (MT2002)" error.

Too bad..

Posted on: June 17, 2013 / Version: 1.3.3