aspose file tools*
The moose likes Other JSE/JEE APIs and the fly likes Unable to get the list of folders in hotmail using JavaMail Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Unable to get the list of folders in hotmail using JavaMail" Watch "Unable to get the list of folders in hotmail using JavaMail" New topic
Author

Unable to get the list of folders in hotmail using JavaMail

Sanjeev Debnath
Greenhorn

Joined: May 25, 2007
Posts: 16
Hi Everyone,

I am writing one simple email client and trying to access the hotmail through the java mail client.
I succeeded to login to hotmail account, but I am getting only INBOX folder.
I want to access the list of folders in Hotmail, like the user created and the default ones for ex. Sent, Draft etc.
One more issue I am facing is unable to use Authenticator to use with POP3. In other words, I want to use the SSL for pop3 connection to login to hotmail.
Below one is my program which is used to login and displays that it has only 1 folder i.e INBOX and when I check for other folder whether it exists or not, it returns false.


If any one knows how to get the list of folders in an email account using pop3, please help me.
Thank you.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42930
    
  68
You can't. POP3 doesn't support more than one folder per user - that's something done by the webmail software.

What is the relationship between using an authenticator (which is used for the password) and using SSL?
Sanjeev Debnath
Greenhorn

Joined: May 25, 2007
Posts: 16
Thank you for the reply.

If POP3 cannot retrieve more than one folder, then which protocol I have to use? I heard about IMAP but haven't tried yet.
I assumed to authenticate the login by using Authenticator.
And I read in many blogs for making any pop3 request, we need to make the SSL flag to true.
Thats what I wanted to ask, that how we can I set the flag isSSL property to true? I noticed this flag in the debug information.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42930
    
  68
If POP3 cannot retrieve more than one folder, then which protocol I have to use? I heard about IMAP but haven't tried yet.

IMAP supports folders, but I'm not sure if Hotmail supports IMAP. Most free webmail solutions don't.

And I read in many blogs for making any pop3 request, we need to make the SSL flag to true.

SSL is an optional feature. Whether or not it's required depends entirely on the host you're connecting to, not the protocol used. Check the online help for what's required by Hotmail.

You should read through Sun's extensive JavaMail FAQ, which has an entry on how to connect to Hotmail: http://java.sun.com/products/javamail/FAQ.html#hotmail
Sanjeev Debnath
Greenhorn

Joined: May 25, 2007
Posts: 16
Hi Ulf,

I searched on the net for IMAP support on Hotmail and got to know that Hotmail only support POP3 and SMTP

So the conclusion is that I will not be able to access other folders in hotmail.

Thanks for the explanation and help
 
wood burning stoves
 
subject: Unable to get the list of folders in hotmail using JavaMail