2 Replies Latest reply on Jul 4, 2016 9:12 AM by kerrishotts

    Create Phonegap app with barcode scanner

    SoupVictim

      Hello all,

       

      I am in need of a lot of help with creating an app with barcode/qr code scanner plugins.

       

      I have searched everywhere and found a few examples or plugins and tried getting them to work with no luck. I cannot seem to get the plugin installed correctly as it says it cannot be found or 'barcodeScanner' is undefined. Does not work on phonegap emulator or device it self.

       

      Please could anyone help me out with an example/tutorial for a barcode scanner? Its driving me insane.

       

      Thanks so much.

        • 1. Re: Create Phonegap app with barcode scanner
          baspey

          When you say that you've tried on device, did you use the Phonegap Developer Mobile App? If that's the case, it's normal that the barcode scanner plugin didn't work because most plugins don't work with the Developper App. This app is great to make some testing, but not when plugins are involved.

           

          You have to connect your phone with an USB cable and build the app into it with the command line "phonegap run android".

           

          Please note that the developper mode must be enabled on your phone. It's tricky because this setting is hidden. You have to press 7 times the build number section to make it appear:

           

          How to enable Developer Options on your Android phone or tablet | Greenbot

           

          You can use the command line "adb devices" to make sure that your phone is detected.

          • 2. Re: Create Phonegap app with barcode scanner
            kerrishotts Adobe Community Professional

            @OP,

             

            Please indicate exactly which plugins you tried, the version #s of those plugins, and how they failed. Share the code of how you used those plugins as well, since that might help us narrow down the issue. It might also help to see your config.xml and index.html (minus identifying information).

             

            Also, what are you using to build the app? PhoneGap Build, PhoneGap CLI, Cordova CLI? Or as @baspey asked, are you using the developer app?

             

            And finally, what platforms are you targeting/testing on (include version numbers)?