Google Places API可以在Android棒棒糖及以下版本上運行嗎?
由於某些手機與我的應用程序,使用谷歌的地方給了這個錯誤:谷歌Places API在棒棒糖及以下
java.lang.ClassNotFoundException:
com.google.android.gms.location.places.Places
java.lang.Class.classForName(Native Method)
java.lang.Class.forName()Class.java:324
md5b74118df040d8158864d95fd3b66e81d.MainActivity.n_onResume(Native Method)
md5b74118df040d8158864d95fd3b66e81d.MainActivity.onResume()MainActivity.java:52
android.app.Instrumentation.callActivityOnResume()Instrumentation.java:1281
android.app.Activity.performResume()Activity.java:6320
android.app.ActivityThread.performResumeActivity()ActivityThread.java:3110
android.app.ActivityThread.handleResumeActivity()ActivityThread.java:3152
android.app.ActivityThread.handleLaunchActivity()ActivityThread.java:2495
at android.app.ActivityThread.-wrap11(ActivityThread.java)
android.app.ActivityThread$H.handleMessage()ActivityThread.java:1354
android.os.Handler.dispatchMessage()Handler.java:102
android.os.Looper.loop()Looper.java:148
android.app.ActivityThread.main()ActivityThread.java:5443
java.lang.reflect.Method.invoke(Native Method)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run()ZygoteInit.java:728
com.android.internal.os.ZygoteInit.main()ZygoteInit.java:618
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.android.gms.location.places.Places" on path: DexPathList[[zip file "/mnt/expand/e7a5152a-8805-4bc2-8125-c715c5d4ff20/app/torathamachane.torathamachane-2/base.apk"],nativeLibraryDirectories=[/mnt/expand/e7a5152a-8805-4bc2-8125-c715c5d4ff20/app/torathamachane.torathamachane-2/lib/arm, /mnt/expand/e7a5152a-8805-4bc2-8125-c715c5d4ff20/app/torathamachane.torathamachane-2/base.apk!/lib/armeabi-v7a, /vendor/lib, /system/lib]]
1.清潔和重建項目。 2.關閉並重新打開您的項目。其中一人應該解決你的問題我猜 – ash12
@ ash12在我的手機上它工作。只有當我發佈併發布它時,一些有棒棒糖和以下的人說應用程序崩潰了。 – amitairos
是否安裝了谷歌播放服務? –