0
私のアプリケーションは、onDestroy()機能を実装する前にほんの数分で作業していました。それは動作しませんでしたので、私のアプリはスプラッシュ画面を通過しないことを見つけるためにそれを取り除きました。誰かを助けることができますか?感謝の下にログ猫。アプリケーションは以前は動作していましたが、今は動作しません。 Log cat
06-23 13:24:55.486: INFO/ActivityManager(164): Start proc com.example.sdr for activity com.example.sdr/.SplashMain: pid=8700 uid=10063 gids={3003}
06-23 13:24:55.786: DEBUG/dalvikvm(8700): GC_EXTERNAL_ALLOC freed 663 objects/51760 bytes in 100ms
06-23 13:24:56.236: INFO/ActivityManager(164): Displayed activity com.example.sdr/.SplashMain: 770 ms (total 242823 ms)
06-23 13:25:01.106: INFO/ActivityManager(164): Starting activity: Intent { act=com.example.sdr.CLEARSCREEN cmp=com.example.sdr/.MainTab }
06-23 13:25:01.216: DEBUG/AndroidRuntime(8700): Shutting down VM
06-23 13:25:01.226: WARN/dalvikvm(8700): threadid=1: thread exiting with uncaught exception (group=0x400207e8)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): FATAL EXCEPTION: main
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.sdr/com.example.sdr.MainTab}: java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.example.sdr/com.example.sdr.PlaylistActivity}: java.lang.NullPointerException
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2663)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.access$2300(ActivityThread.java:125)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.os.Handler.dispatchMessage(Handler.java:99)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.os.Looper.loop(Looper.java:123)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.main(ActivityThread.java:4627)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at java.lang.reflect.Method.invokeNative(Native Method)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at java.lang.reflect.Method.invoke(Method.java:521)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at dalvik.system.NativeStart.main(Native Method)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): Caused by: java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.example.sdr/com.example.sdr.PlaylistActivity}: java.lang.NullPointerException
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2585)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.startActivityNow(ActivityThread.java:2503)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.LocalActivityManager.moveToState(LocalActivityManager.java:127)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.LocalActivityManager.startActivity(LocalActivityManager.java:339)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.widget.TabHost$IntentContentStrategy.getContentView(TabHost.java:676)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.widget.TabHost.setCurrentTab(TabHost.java:348)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.widget.TabHost.addTab(TabHost.java:227)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at com.example.sdr.MainTab.onCreate(MainTab.java:27)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): ... 11 more
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): Caused by: java.lang.NullPointerException
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.Activity.findViewById(Activity.java:1637)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at com.example.sdr.PlaylistActivity.<init>(PlaylistActivity.java:93)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at java.lang.Class.newInstanceImpl(Native Method)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at java.lang.Class.newInstance(Class.java:1429)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.Instrumentation.newActivity(Instrumentation.java:1021)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2577)
06-23 13:25:01.286: ERROR/AndroidRuntime(8700): ... 20 more
これは正しく定義されています。私は決してそれで回り込むことがなかったので、何ができるか分からない。 – Splitusa
プロジェクトをクリーンアップします。 – piotrpo
'findViewById()'でビューを取得する前に 'setContentView(R.layout.main);'を呼び出して、 – Houcine