06-26 17:07:09.898: E/AndroidRuntime(380): FATAL EXCEPTION: main
06-26 17:07:09.898: E/AndroidRuntime(380): java.lang.NoClassDefFoundError: org.mythrii.email.Mail
06-26 17:07:09.898: E/AndroidRuntime(380): at org.mythrii.email.Email$1.onClick(Email.java:19)
06-26 17:07:09.898: E/AndroidRuntime(380): at android.view.View.performClick(View.java:2485)
06-26 17:07:09.898: E/AndroidRuntime(380): at android.view.View$PerformClick.run(View.java:9080)
06-26 17:07:09.898: E/AndroidRuntime(380): at android.os.Handler.handleCallback(Handler.java:587)
06-26 17:07:09.898: E/AndroidRuntime(380): at android.os.Handler.dispatchMessage(Handler.java:92)
06-26 17:07:09.898: E/AndroidRuntime(380): at android.os.Looper.loop(Looper.java:123)
06-26 17:07:09.898: E/AndroidRuntime(380): at android.app.ActivityThread.main(ActivityThread.java:3683)
06-26 17:07:09.898: E/AndroidRuntime(380): at java.lang.reflect.Method.invokeNative(Native Method)
06-26 17:07:09.898: E/AndroidRuntime(380): at java.lang.reflect.Method.invoke(Method.java:507)
06-26 17:07:09.898: E/AndroidRuntime(380): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
06-26 17:07:09.898: E/AndroidRuntime(380): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
06-26 17:07:09.898: E/AndroidRuntime(380): at dalvik.system.NativeStart.main(Native Method)
Asked
Active
Viewed 105 times
0
-
1It means `Mail.java` doesn't exist i think. – Praveenkumar Jun 26 '12 at 11:57
-
are you using any external library? – Dinesh Prajapati Jun 26 '12 at 11:57
-
Shouldn't `org.mythrii.email.Mail` be `org.mythrii.email.Email`? – pawelzieba Jun 26 '12 at 11:57
-
thanks for your reply ya Mail.java is present in that file mail code is present – raju Jun 26 '12 at 11:59
-
ya iam using external lib file Mail.jar,activation.jar and additional.jar files – raju Jun 26 '12 at 12:02
-
[Follow the steps properly](http://stackoverflow.com/a/2033124/940096) – Praveenkumar Jun 26 '12 at 12:03
-
3Is that from a library? If it is, the library jar needs to be in the `/libs` directory. – Barak Jun 26 '12 at 12:04
-
Try to clean your project. Or try to restart your work-space and run it again. – Praveenkumar Jun 26 '12 at 12:15
2 Answers
3
The solution to this problem is to create a folder named "libs" in the project directory and copying all the external jar files there.
For further explanation, you can refer to this link.
http://tools.android.com/recent/dealingwithdependenciesinandroidprojects

Swayam
- 16,294
- 14
- 64
- 102
-
-
-
1If it still does not work, try adding the jar file to the project build path by right clicking on the jar file and "Add it to build". – Swayam Jun 26 '12 at 12:14
1
I think what you face is that your code compiles , but @ run time it crashes . How do i solve this , create a libs
folder in your project inside eclipse(if its not exist) and add the jar file that contains the org.mythrii.email.Mail
class inside the libs
folder , Then run you app .

confucius
- 13,127
- 10
- 47
- 66