Search code examples
androidadbzxing

Cannot start ZXing from adb shell


I downloaded the latest Barcode Scanner (https://code.google.com/p/zxing/downloads/detail?name=BarcodeScanner4.5.apk&can=3&q=Barcode+Scanner) and installed it onto my device. Here it is:

shell@android:/ $ pm list packages -3
package:com.google.zxing.client.android

Yet, when I try to run it, the class cannot be found:

shell@android:/ $ am start -n com.google.zxing.client.android/.SCAN            
Starting: Intent { cmp=com.google.zxing.client.android/.SCAN }
Error type 3
Error: Activity class {com.google.zxing.client.android/com.google.zxing.client.android.SCAN} does not exist.

Am I using the correct class?


Solution

  • You seem to be confusing the intent action with the class name. You can see from the manifest that the activity's class is .CaptureActivity.