首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > Android >

帮忙看一下报错log信息,该怎么解决

2012-05-14 
帮忙看一下报错log信息05-12 05:18:42.982: D/AndroidRuntime(980): Shutting down VM05-12 05:18:42.982:

帮忙看一下报错log信息
05-12 05:18:42.982: D/AndroidRuntime(980): Shutting down VM
05-12 05:18:42.982: W/dalvikvm(980): threadid=1: thread exiting with uncaught exception (group=0x4001d800)
05-12 05:18:43.002: E/AndroidRuntime(980): FATAL EXCEPTION: main
05-12 05:18:43.002: E/AndroidRuntime(980): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.kevin/com.kevin.KevinActivity}: java.lang.NullPointerException
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2663)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.ActivityThread.access$2300(ActivityThread.java:125)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.os.Handler.dispatchMessage(Handler.java:99)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.os.Looper.loop(Looper.java:123)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.ActivityThread.main(ActivityThread.java:4627)
05-12 05:18:43.002: E/AndroidRuntime(980): at java.lang.reflect.Method.invokeNative(Native Method)
05-12 05:18:43.002: E/AndroidRuntime(980): at java.lang.reflect.Method.invoke(Method.java:521)
05-12 05:18:43.002: E/AndroidRuntime(980): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
05-12 05:18:43.002: E/AndroidRuntime(980): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
05-12 05:18:43.002: E/AndroidRuntime(980): at dalvik.system.NativeStart.main(Native Method)
05-12 05:18:43.002: E/AndroidRuntime(980): Caused by: java.lang.NullPointerException
05-12 05:18:43.002: E/AndroidRuntime(980): at com.kevin.KevinActivity.onCreate(KevinActivity.java:38)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
05-12 05:18:43.002: E/AndroidRuntime(980): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
05-12 05:18:43.002: E/AndroidRuntime(980): ... 11 more
05-12 05:23:43.452: I/Process(980): Sending signal. PID: 980 SIG: 9

[解决办法]
05-12 05:18:43.002: E/AndroidRuntime(980): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.kevin/com.kevin.KevinActivity}: java.lang.NullPointerException
空指针异常,楼主查看一下,在AndroidManifest.xml中,是否正确地注册了Activity。

热点排行