为了账号安全,请及时绑定邮箱和手机立即绑定

崩掉了,求解

05-26 22:06:10.601: D/AndroidRuntime(3119): Shutting down VM

05-26 22:06:10.601: W/dalvikvm(3119): threadid=1: thread exiting with uncaught exception (group=0xb3aebba8)

05-26 22:06:10.621: E/AndroidRuntime(3119): FATAL EXCEPTION: main

05-26 22:06:10.621: E/AndroidRuntime(3119): Process: com.example.viewflipper, PID: 3119

05-26 22:06:10.621: E/AndroidRuntime(3119): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.viewflipper/com.example.viewflipper.MainActivity}: java.lang.ArrayIndexOutOfBoundsException: length=4; index=4

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2195)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.ActivityThread.access$800(ActivityThread.java:135)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.os.Handler.dispatchMessage(Handler.java:102)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.os.Looper.loop(Looper.java:136)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.ActivityThread.main(ActivityThread.java:5017)

05-26 22:06:10.621: E/AndroidRuntime(3119): at java.lang.reflect.Method.invokeNative(Native Method)

05-26 22:06:10.621: E/AndroidRuntime(3119): at java.lang.reflect.Method.invoke(Method.java:515)

05-26 22:06:10.621: E/AndroidRuntime(3119): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)

05-26 22:06:10.621: E/AndroidRuntime(3119): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)

05-26 22:06:10.621: E/AndroidRuntime(3119): at dalvik.system.NativeStart.main(Native Method)

05-26 22:06:10.621: E/AndroidRuntime(3119): Caused by: java.lang.ArrayIndexOutOfBoundsException: length=4; index=4

05-26 22:06:10.621: E/AndroidRuntime(3119): at com.example.viewflipper.MainActivity.onCreate(MainActivity.java:23)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.Activity.performCreate(Activity.java:5231)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)

05-26 22:06:10.621: E/AndroidRuntime(3119): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2159)

05-26 22:06:10.621: E/AndroidRuntime(3119): ... 11 more


正在回答

2 回答

com.example.viewflipper/com.example.viewflipper.MainActivity}: java.lang.ArrayIndexOutOfBoundsException: length=4; index=4,
数组越界了

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消
Android攻城狮的第二门课(第1季)
  • 参与学习       111171    人
  • 解答问题       1457    个

本课程由浅入深地带您学会Android的常用控件的开发和使用

进入课程

崩掉了,求解

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信