定时器出错?

时间:2014-01-28 09:11:44

标签: android timer

我想问为什么我的代码现在给我错误?我只是从我的计时器活动中复制它只对我的其他活动有效并且突然它给我一个错误?

这是我的代码

* logcat的

01-28 16:41:34.900: W/dalvikvm(9387): threadid=1: thread exiting with uncaught exception (group=0x4164a8a8)
01-28 16:41:34.910: E/AndroidRuntime(9387): FATAL EXCEPTION: main
01-28 16:41:34.910: E/AndroidRuntime(9387): java.lang.NullPointerException
01-28 16:41:34.910: E/AndroidRuntime(9387):     at com.thesis.logipic.Gameplay$MyCount.onTick(Gameplay.java:2776)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at android.os.CountDownTimer$1.handleMessage(CountDownTimer.java:124)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at android.os.Handler.dispatchMessage(Handler.java:99)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at android.os.Looper.loop(Looper.java:153)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at android.app.ActivityThread.main(ActivityThread.java:4987)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at java.lang.reflect.Method.invokeNative(Native Method)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at java.lang.reflect.Method.invoke(Method.java:511)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:821)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:584)
01-28 16:41:34.910: E/AndroidRuntime(9387):     at dalvik.system.NativeStart.main(Native Method)
01-28 16:41:36.152: D/AudioTrack(9387): audiotrack 0x52b30c10 stop done

*定时器活动

http://pastebin.com/7ybnTm9R

*我的活动

http://pastebin.com/bAEszRpL

0 个答案:

没有答案