Scan image from library

Apr 29, 2012 at 11:09 AM

The sample works fine for me where it loads the sample images from a URL, and returns the result. But I am trying to bring up the PhotoChooser and select a photo of a QR Code, but it always fails. This seems like a bug.


 void photoSelection_Completed(object sender, PhotoResult e)
            if (e.TaskResult == TaskResult.OK)
                BitmapImage bitmap = new BitmapImage { CreateOptions = BitmapCreateOptions.None };
             WP7BarcodeManager.ScanMode = BarcodeFormat.QR_CODE;
                WP7BarcodeManager.ScanBarcode(bitmap, Barcode_Results);
            else if (e.TaskResult == TaskResult.None)
                MessageBox.Show(e.Error.Message, "There was an error", MessageBoxButton.OK);

When it gets back to the Barcode_Results delegate it says "Error: Cannot decode barcode image. Please make sure scan mode is correct and try again.".



Apr 4, 2014 at 2:37 AM
Edited Apr 4, 2014 at 2:38 AM
Don't you use a Silverlightzxing barcode reading library to decode barcode image?
Apr 16, 2014 at 3:42 AM
Edited May 31, 2015 at 6:08 AM
I've ever tried ZXing QRCode Barcode Scanning Library and met the similar problem. Thanks for you suggestion and i'd like to check it out.