小编ale*_*exx的帖子

Google Maps Android API v2 - 示例代码崩溃

我正在尝试使用Android"Google Maps Android API v2" 的示例代码.我没有错误地构建项目.但是,当我尝试在我的Galaxy Nexus上运行应用程序(与usb连接到我的笔记本电脑)时,应用程序立即崩溃.

  • 我在AndroidManifest.xml上填写了我自己的Maps API密钥
  • 我是针对Android 4.1.2构建的

这是日志记录:

Unable to resolve superclass of Lcom/example/mapdemo/BasicMapActivity; (66) 
Link of class 'Lcom/example/mapdemo/BasicMapActivity;' failed 
Could not find class 'com.example.mapdemo.BasicMapActivity', referenced from method com.example.mapdemo.MainActivity.<clinit> 
VFY: unable to resolve const-class 108 (Lcom/example/mapdemo/BasicMapActivity;) in Lcom/example/mapdemo/MainActivity; 
VFY: replacing opcode 0x1c at 0x000d 
Exception Ljava/lang/NoClassDefFoundError; thrown while initializing Lcom/example/mapdemo/MainActivity; 
Class init failed in newInstance call (Lcom/example/mapdemo/MainActivity;) 
Shutting down VM 
threadid=1: thread exiting with uncaught exception (group=0x41ac9930) 
FATAL EXCEPTION: main 
java.lang.ExceptionInInitializerError
at java.lang.Class.newInstanceImpl(Native Method) …
Run Code Online (Sandbox Code Playgroud)

crash maps android sample google-maps-android-api-2

43
推荐指数
3
解决办法
4万
查看次数

标签 统计

android ×1

crash ×1

google-maps-android-api-2 ×1

maps ×1

sample ×1