Multiple errors when trying to integrate barcode scanner application in my own android application

StackOverflow https://stackoverflow.com/questions/11327091

Domanda

I'm pretty new in Android programming, so sorry if I am going to ask dumb questions.

I'm creating an application, and I'm trying to integrate ZXing Barcode Scanner, following the instructions here: http://code.google.com/p/zxing/source/browse/trunk/android-integration/src/com/google/zxing/integration/android/IntentIntegrator.java

What I've done so far. I've created some buttons for my application, and put an action On Click for the button supposed to use ZXing for scanning. Value: IntentIntegrator. Then I've copy-pasted the code from the link into the file IntentIntegrator.java from my package. Following the advices given in eclipse I've created IntentResult class in com.google.zxing.integration.android package.

Here I am in this moment. For 2 days I've been reading advices, opinions, I've done started all from the beginning but it didn't work. So I'm trying again. Can anyone tell me please, step by step, how to integrate this app in my own? Or if I am right with what I've done so far, why when I run as Android project on the emulator, I get at least 20 errors, like these for exemple: http://s17.postimage.org/n9w5lddof/errors.png

Thank you!

È stato utile?

Soluzione

You have done basically the right thing. You are however including multiple copies of IntentIntegrator or have compiled against a different version than you are bundling. That is, no you have not really integrated this correctly as indicated.

The fastest thing is to copy both classes into your source tree. No other JARs or source files are needed.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top