JavaMail in Android
in
Android Processing
•
2 years ago
I've been trying to get Daniel Shiffman's e-mail sketch to work on Android:
http://www.shiffman.net/2007/11/13/e-mail-processing/
I've had no luck as yet. The sketch launches on the phone and runs without any problems until I press the button to send an email (I'm using a PButton apwidget as a trigger). This is the error that I get in Processing when the button is pressed:
- java.lang.reflect.InvocationTargetException
- at processing.android.test.questionnaire_20110404.questionnaire_20110404.onClickWidget(questionnaire_20110404.java:168)
- at java.lang.reflect.Method.invokeNative(Native Method)
- at java.lang.reflect.Method.invoke(Method.java:521)
- at apwidgets.PWidget.onClick(PWidget.java:69)
- at android.view.View.performClick(View.java:2418)
- at android.view.View.onTouchEvent(View.java:4233)
- at android.widget.TextView.onTouchEvent(TextView.java:6645)
- at android.view.View.dispatchTouchEvent(View.java:3763)
- at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:968)
- at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:968)
- at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:968)
- at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:968)
- at com.android.internal.policy.impl.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:1659)
- at com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1107)
- at android.app.Activity.dispatchTouchEvent(Activity.java:2064)
- at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:1643)
- at android.view.ViewRoot.handleMessage(ViewRoot.java:1691)
- at android.os.Handler.dispatchMessage(Handler.java:99)
- at android.os.Looper.loop(Looper.java:123)
- at android.app.ActivityThread.main(ActivityThread.java:4370)
- at java.lang.reflect.Method.invokeNative(Native Method)
- at java.lang.reflect.Method.invoke(Method.java:521)
- at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
- at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
- at dalvik.system.NativeStart.main(Native Method)
- Caused by: java.lang.NoClassDefFoundError: javax.activation.DataHandler
- at javax.mail.internet.MimeMessage.setContent(MimeMessage.java:1383)
- at javax.mail.internet.MimeBodyPart.setText(MimeBodyPart.java:892)
- at javax.mail.internet.MimeMessage.setText(MimeMessage.java:1416)
- at javax.mail.internet.MimeMessage.setText(MimeMessage.java:1404)
- at processing.android.test.questionnaire_20110404.questionnaire_20110404.sendMail(questionnaire_20110404.java:306)
- ... 25 more
1