I'm trying to write a simple app to access my mail inbox, check if there is any new mail and open that meail. the source code for POP3 mail is from http://forums.sun.com/thread.jspa?threadID=5267916, then add mail.jar, activation.jar to my project. I managed to compile and run the app on Google G1, but it crashed and report as below:
Failed resolving Ljavax/activation/DataHandler; interface 172 'Ljava/ awt/datatransfer/Transferable;' Link of class 'Ljavax/activation/DataHandler;' failed VFY: unable to find class referenced in signature (Ljavax/activation/ DataHandler;) Failed resolving Ljavax/activation/DataHandler; interface 172 'Ljava/ awt/datatransfer/Transferable;' Link of class 'Ljavax/activation/DataHandler;' failed Could not find method javax.activation.DataHandler.getContent, referenced from method javax.mail.internet.MimeMessage.getContent VFY: unable to resolve virtual method 1619: Ljavax/activation/ DataHandler;.getContent ()Ljava/lang/Object; VFY: rejecting opcode 0x6e at 0x0004 VFY: rejected Ljavax/mail/internet/MimeMessage;.getContent ()Ljava/ lang/Object; Verifier rejected class Ljavax/mail/internet/MimeMessage; java.lang.VerifyError: javax.mail.internet.MimeMessage at com.sun.mail.pop3.POP3Folder.createMessage(POP3Folder.java:299) at com.sun.mail.pop3.POP3Folder.getMessage(POP3Folder.java:280) at javax.mail.Folder.getUnreadMessageCount(Folder.java:728) at android.test.mail..MailJar.onCreate(MailJar.java:36) at android.app.Instrumentation.callActivityOnCreate (Instrumentation.java:1123) at android.app.ActivityThread.performLaunchActivity (ActivityThread.java:2364) at android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2417) at android.app.ActivityThread.access$2100(ActivityThread.java:116) at android.app.ActivityThread$H.handleMessage(ActivityThread.java: 1794) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:123) at android.app.ActivityThread.main(ActivityThread.java:4203) 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:791) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) at dalvik.system.NativeStart.main(Native Method) i tried to get java.awt.datatransfer package from rt.jar of jre6, but it failed to compile, and reported [2010-01-05 17:02:53 - MailJar] trouble processing "java/awt/Image.class": [2010-01-05 17:02:53 - MailJar] Attempt to include a core VM class in something other than a core library. It is likely that you have attempted to include the core library from a desktop virtual machine into an application, which will most assuredly not work. If you really intend to build a core library -- which is only appropriate as part of creating a full virtual machine binary, as opposed to compiling an application -- then use the "--core-library" option to suppress this error message. If you go ahead and use "--core-library" but are in fact building an application, then please be aware that your build will still fail at some point; you will simply be denied the pleasure of reading this helpful error message. [2010-01-05 17:02:53 - MailJar] 1 error; aborting [2010-01-05 17:02:53 - MailJar] Conversion to Dalvik format failed with error 1 Then i read from somewhere, that java.awt.datatransfer should be downloaded from Apache Harmony SVN, so i tried to look for it there, but no hope -.-" can any1 help me to solve this? thanks in advance
-- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en