how to get yahoo mails in to android app programtically
<p>I want to show all yahoomail mails in my android app. Using Imap is it possible?
  Does Imap supports yahoomail.? Can any one please help me.</p>

<p>Following is the code I tried.</p>

<pre><code>following is the code to get yahoomails

   public void getYahooMails(View V) throws MessagingException {

    try {

        store = imapSession.getStore("imaps");

        store.connect("imap.mail.yahoo.com", "username", "password");
        System.out.println("*******Message here********"
                + store.isConnected());
        if (store.isConnected()) {
            inbox = store.getFolder("Inbox");
            inbox.open(Folder.READ_ONLY);
            Message[] result = inbox.getMessages();
            System.out.println(result.length + "======"
                    + inbox.getUnreadMessageCount());

            /*
             * for(int i=result.length;i&gt;0;i--) { if(i==1000) {
             * System.out.println
             * (result[i].getSubject()+"=====mesaage ====&gt;"
             * +result[i].getSentDate()); } }
             */

        }
    } catch (Exception w) {

        // w.printStackTrace();
        System.out.println("*******Message here********"
                + store.isConnected());
        // System.out.println(w.getMessage());
        w.printStackTrace();
    }

}
</code></pre>
