我已經導入了一個現有的項目到eclipse和所有需要的庫,並且現在沒有任何錯誤。但是,當我嘗試編譯應用程序時,它仍然崩潰,只要它應該在Android設備上運行。這是logcat文件:我不知道這個logcat文件告訴我什麼
07-16 18:49:13.187: E/AndroidRuntime(12183): FATAL EXCEPTION: main
07-16 18:49:13.187: E/AndroidRuntime(12183): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{si.dvanadva.evanturist/si.dvanadva.evanturist.MainActivity}: java.lang.ClassNotFoundException: Didn't find class "si.dvanadva.evanturist.MainActivity" on path: /data/app/si.dvanadva.evanturist-2.apk
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2106)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2230)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.ActivityThread.access$600(ActivityThread.java:141)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1234)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.os.Handler.dispatchMessage(Handler.java:99)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.os.Looper.loop(Looper.java:137)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.ActivityThread.main(ActivityThread.java:5041)
07-16 18:49:13.187: E/AndroidRuntime(12183): at java.lang.reflect.Method.invokeNative(Native Method)
07-16 18:49:13.187: E/AndroidRuntime(12183): at java.lang.reflect.Method.invoke(Method.java:511)
07-16 18:49:13.187: E/AndroidRuntime(12183): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
07-16 18:49:13.187: E/AndroidRuntime(12183): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
07-16 18:49:13.187: E/AndroidRuntime(12183): at dalvik.system.NativeStart.main(Native Method)
07-16 18:49:13.187: E/AndroidRuntime(12183): Caused by: java.lang.ClassNotFoundException: Didn't find class "si.dvanadva.evanturist.MainActivity" on path: /data/app/si.dvanadva.evanturist-2.apk
07-16 18:49:13.187: E/AndroidRuntime(12183): at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:65)
07-16 18:49:13.187: E/AndroidRuntime(12183): at java.lang.ClassLoader.loadClass(ClassLoader.java:501)
07-16 18:49:13.187: E/AndroidRuntime(12183): at java.lang.ClassLoader.loadClass(ClassLoader.java:461)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.Instrumentation.newActivity(Instrumentation.java:1054)
07-16 18:49:13.187: E/AndroidRuntime(12183): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2097)
07-16 18:49:13.187: E/AndroidRuntime(12183): ... 11 more
07-16 18:49:27.664: E/fb4a(:<default>):MmsConfig(12350): MmsConfig.loadMmsSettings mms_config.xml missing uaProfUrl setting
任何人都可以幫助我如何解決這個問題?
包了'si.dvanadva.evanturist.MainActivity'類? –
只需掃描logcat的用於「 causedby」,你會看到確切的問題'產生的原因:拋出java.lang.ClassNotFoundException:找不到類‘路徑si.dvanadva.evanturist.MainActivity’:/data/app/si.dvanadva.evanturist-2.apk ' – Nick
@DaveNewton抱歉推遲答覆,但你到底是什麼意思? – Guy