我有一个简单的应用程序,您可以在textvIEw中输入文本,然后按submit,它会在另一个Activity中显示文本.但是,当我按“提交”时,给我消息“不幸的是,发送已停止”,我查看了SO上的其他线程,但是Unfortunately myfirstproject stopped working error in java似乎是最接近的线程,他们说要检查LogCat文件,但它提出了多个错误:
07-11 19:38:01.925: E/Trace(729): error opening trace file: No such file or directory (2)07-11 19:38:05.815: I/Choreographer(729): Skipped 451 frames! The application may be doing too much work on its main thread.07-11 19:38:06.009: D/gralloc_goldfish(729): Emulator without GPU emulation detected.07-11 19:38:35.046: I/Choreographer(729): Skipped 45 frames! The application may be doing too much work on its main thread.07-11 19:38:41.427: D/AndroIDRuntime(729): Shutting down VM07-11 19:38:41.435: W/dalvikvm(729): threadID=1: thread exiting with uncaught exception (group=0x40a13300)07-11 19:38:41.585: E/AndroIDRuntime(729): FATAL EXCEPTION: main07-11 19:38:41.585: E/AndroIDRuntime(729): java.lang.IllegalStateException: Could not execute method of the activity07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.vIEw.VIEw.onClick(VIEw.java:3591)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.vIEw.VIEw.performClick(VIEw.java:4084)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.vIEw.VIEw$PerformClick.run(VIEw.java:16966)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.os.Handler.handleCallback(Handler.java:615)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.os.Handler.dispatchMessage(Handler.java:92)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.os.Looper.loop(Looper.java:137)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.ActivityThread.main(ActivityThread.java:4745)07-11 19:38:41.585: E/AndroIDRuntime(729): at java.lang.reflect.Method.invokeNative(Native Method)07-11 19:38:41.585: E/AndroIDRuntime(729): at java.lang.reflect.Method.invoke(Method.java:511)07-11 19:38:41.585: E/AndroIDRuntime(729): at com.androID.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)07-11 19:38:41.585: E/AndroIDRuntime(729): at com.androID.internal.os.ZygoteInit.main(ZygoteInit.java:553)07-11 19:38:41.585: E/AndroIDRuntime(729): at dalvik.system.NativeStart.main(Native Method)07-11 19:38:41.585: E/AndroIDRuntime(729): Caused by: java.lang.reflect.InvocationTargetException07-11 19:38:41.585: E/AndroIDRuntime(729): at java.lang.reflect.Method.invokeNative(Native Method)07-11 19:38:41.585: E/AndroIDRuntime(729): at java.lang.reflect.Method.invoke(Method.java:511)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.vIEw.VIEw.onClick(VIEw.java:3586)07-11 19:38:41.585: E/AndroIDRuntime(729): ... 11 more07-11 19:38:41.585: E/AndroIDRuntime(729): Caused by: androID.content.ActivityNotFoundException: Unable to find explicit activity class {com.point/com.point.displayMessageActivity}; have you declared this activity in your AndroIDManifest.xml?07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1541)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.Instrumentation.execStartActivity(Instrumentation.java:1416)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.Activity.startActivityForResult(Activity.java:3351)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.Activity.startActivityForResult(Activity.java:3312)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.Activity.startActivity(Activity.java:3522)07-11 19:38:41.585: E/AndroIDRuntime(729): at androID.app.Activity.startActivity(Activity.java:3490)07-11 19:38:41.585: E/AndroIDRuntime(729): at com.point.MainActivity.sendMessage(MainActivity.java:34)07-11 19:38:41.585: E/AndroIDRuntime(729): ... 14 more07-11 19:43:41.995: I/Process(729): Sending signal. PID: 729 SIG: 9
@H_403_7@SO上的链接还说了一些关于不创建TextVIEw的信息,并且它为NulL.
有人能帮我吗?
解决方法:
如果您更好地查看错误日志,将会看到:
Caused by: androID.content.ActivityNotFoundException: Unable to find explicit activity class {com.point/com.point.displayMessageActivity}; have you declared this activity in your AndroIDManifest.xml?
那么,您的displayMessageActivity是否在AndroIDManifest.xml文件中声明?
总结以上是内存溢出为你收集整理的java-不幸的是Project_Name已停止全部内容,希望文章能够帮你解决java-不幸的是Project_Name已停止所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)