How can i recieve unread message from pop3 server

hi ! i'm using pop3 server
I used the following code to set read message.
String host="servername";
String username="xx.domainname";
String password="xxxxxx";
try
Session mySession=Session.getDefaultInstance(System.getProperties(),null);
               mySession.setDebug(true);
          //get a specific mail storage
      myStore=mySession.getStore("pop3");
// Store myStore=(Store)session.getAttribute("myStore");
myStore.connect(host,username,password);
myFolder= myStore.getFolder("INBOX");
if (myFolder == null)
                    System.err.println("No inbox folder is available");
               else
                    System.out.println("Accessing"+ myFolder.getFullName()+"folder========" );
               myFolder.open(Folder.READ_WRITE);
Message[] message=myFolder.getMessages();
  message.setFlag(Flags.Flag.SEEN,true);
System.out.println("Flags ========: "+message[i].getFlags());
myFolder.close(true);
myStore.close();
catch(Exception e)
Again if i receive  message from server it is not showing unread messages. it will return as 0.(I used the  method *getUnreadMessageCount()*)
Can i have some help
Thanks in advance.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

The POP3 protocol supports no flags.
See the FAQ and the javadocs for the com.sun.mail.pop3 package.

Similar Messages

  • How can i print text messages from my htc amaze to my deskjet 3050A

    how can i print text messages from my htc amaze to my hp deskjet 3050A

    Hi,
    I believe the phone uses Android OS, v2.3.4 (Gingerbread) therefore you can use one of these applications:
       http://www.printeron.com/apps/androidprinting.html
       https://market.android.com/details?id=com.pauloslf​.cloudprint&hl=en
    Regards.
    BH
    **Click the KUDOS thumb up on the left to say 'Thanks'**
    Make it easier for other people to find solutions by marking a Reply 'Accept as Solution' if it solves your problem.

  • How can I send a message from database to a J2EE application?

    How can I send a message from database to a J2EE application?
    If I have a codetable in database that has new or modified values I have to refresh the codetable in my J2EE application.
    Most effective way would be send a message to initiate a table reload from J2EE app, but I don't know how to do this.
    Now I have a background thread that regular reads the table and looks for changes.

    http://www.oracle.com/technology/products/integration/bam/10.1.3/TechNotes/TechNote_BAM_AQ_Configuration.pdf
    This document details how to create triggers on a table that send out JMS messages.
    In this example, the messages are going to Oracle BAM.. your message could go to your J2EE application listening to its own topic/queue.
    an alternative idea.
    you could also just cache your lookup table with something like Oracle Coherence and than try to ensure that all changes to the lookup go through Coherence, so that you won't need to do notification from the db up to the application. the application and the lookup data management tool would be using the data grid for management of the lookup table data, and the data grid (coherence) would persist the lookup data changes back to the db.

  • How can I delete text messages from my iphone?

    Hello everyone,
    How can I delete text messages from my iphone?  I do not want to reset my iphone setting. If it is nesscary to reset my iphone setting, will I lose everything?
    Please let me know,
    Thanks,

    Just delete them. Or, do you mean beyond just deleting them? Then, you'd need to wipe the phone - select Settings > General > Reset > Erase All Content and Settings. That's a secure wipe of the iPhone contents, takes several hours (connect to AC power). You'll need to set your phone up from scratch (and erase the old backup(s) from your computer, since your SMS history is part of the backup).

  • How can I remove unread messages when I know I don't have any?

    How can I remove "unread messages" when I know I do not have any?

    Hit the num lock button again. Num lock forces only the numeric keypad underlying keys to work as a  numeric keypad, and the rest of the keyboard won't work.  Unfortunately Apple stopped including the numeric keypad hidden keyboard key labels on its keyboards.  They used to include them.  They are known as mouse keys: http://docs.info.apple.com/article.html?path=Mac/10.5/en/cdb_moskys.html

  • How can i syncronize flagged messages from outlook in icloud

    How can i syncronize flagged messages from outlook in icloud?

    I figured out what I think is the easiest method: I open the file in Preview, select File, then Print, then, at the bottom of the Print dialog box, use the little down arrow on the PDF button to select "Add PDF to iBooks".

  • How can I retrieve deleted messages from Skype?

    How can I retrieve deleted messages from Skype? I tried going to Users then application support but the folder is empty, so I'm stuck I don't know what to do?

    Try the Microsft Skype forums
    You can also try a disk file recovery program like Disk Warrior.

  • How can i restore deleted messages from iphone?

    how can i restore deleted messages from iphone?

    If they were backed up, you can restore your phone from that previous backup.  If they weren't backed up, you cannot restore them.

  • How can I recover deleted messages from iphone 4?

    How can I recover deleted messages from iphone 4?

    You don't.
    E-mail is kept on your e-mail server.
    Have you failed to import your photos to your comptuer regularly?
    If so, then they are likely gone.  You can try restoring from backup.

  • How can i send simple message from PC-to-another device

    How can i send simple message from PC-to-another device
    just simple message (like command String) not SMS or Data File.
    I have a computer with bluetooth and the oter side is Embeded Blue
    Thanks.

    http://www.oracle.com/technology/products/integration/bam/10.1.3/TechNotes/TechNote_BAM_AQ_Configuration.pdf
    This document details how to create triggers on a table that send out JMS messages.
    In this example, the messages are going to Oracle BAM.. your message could go to your J2EE application listening to its own topic/queue.
    an alternative idea.
    you could also just cache your lookup table with something like Oracle Coherence and than try to ensure that all changes to the lookup go through Coherence, so that you won't need to do notification from the db up to the application. the application and the lookup data management tool would be using the data grid for management of the lookup table data, and the data grid (coherence) would persist the lookup data changes back to the db.

  • How can you move the objects from one server to another?

    how can you move the objects from one server to another?

    Hi,
    Collecting objects for Transporting
    1. rsa1->transport connection
    2. left panel choose 'object type', middle panel choose 'infocube' and 'select objects'
    3. then choose your infocube and 'transfer'
    4. will go to right panel, choose collection mode 'manual' and grouping only 'necessary objects'
    5. after objects collection finished, create request
    6. If they are $TMP, then change the package.
    7. When you click the Save on the change package, it will prompt for transport. Here you can provide an existing open transport request number, or if you like here itself you can create a new one.
    8. You can check the request in SE09 to confirm.
    Releasing Transport Request  
    Lets say you are transporting from BWD to BWQ
    Step 1: In BWD go to TCode SE10
    Step 2: Find the request and release it (Truck Icon or option can be found by right click on request #)
    Note: First release the child request and then the parent request
    Steps below are to import transport (generally done by basis )
    Step 1: In BWQ go to Tcode STMS
    Step 2: Click on Import queue button
    Step 3: Double Click on the line which says BWQ (or the system into which transport has to be imported)
    Step 4: Click on refresh button
    Step 5: High light the trasnport request and import it (using the truck icon)
    Transport
    http://help.sap.com/saphelp_nw2004s/helpdata/en/b5/1d733b73a8f706e10000000a11402f/frameset.htm
    http://help.sap.com/saphelp_nw70/helpdata/en/0b/5ee7377a98c17fe10000009b38f842/frameset.htm
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/media/uuid/224381ad-0701-0010-dcb5-d74236082bff
    Hope this helps.
    thanks,
    JituK

  • TS3276 I have an old version, 10.5. A few days ago, my Inbox stopped showing new messages received, although they are coming in and show under Messages on Server.  How can I get the messages on the server to go to my Inbox so I can access them?

    I have an old version, 10.5. A few days ago, my Inbox stopped showing new messages received, although they are coming in and show under Messages on Server.  How can I get the messages on the server to go to my Inbox so I can access them?

    Make sure Mail is selected in System Preferences > iCloud

  • HOW CAN I BLOCK SMS MESSAGES FROM AN SPECIFIC PHONE NUMBER ON MY IPHONE 5

    HOW CAN I BLOCK SMS MESAGES FROM AN SPECIFIC PHONE NUMBER ON MY I PHONE5, THANKS

    You can't. Contact your carrier and ask them if they provide such a service. Most carriers do not, unless the text messages are threatening or harassing, but you can ask.
    Regards.
    Message was edited by: varjak paw; fixed typo.

  • How can i print text message from my iPhone?

    I have an iPhone 5S.  How can I print text messages to save those conversations?

    Did you try to copy and paste the content into another app, like notes or Mail and then send it to the printer?

  • How to remove copy of message from .Mac server

    To autoremove the copy of a message on the .Mac server, Mail help says "choose Mail > Preferences and click Accounts. Select a .Mac or IMAP account, click Mailbox Behaviors, and change the option for storing messages on the server."
    Unfortunately, that option seems to be missing from both the "Mailbox Behaviors" and "Advanced" tabs.
    I have a separate pop account from another ISP that does have the option under the "Advanced" tab.
    Does anyone know how to do this for the .Mac account?
    Thanks!
    Jim
    iMac 24"   Mac OS X (10.4.9)   Mail version 2.1.1

    A .Mac type account with Mail is really an IMAP account and behaves in the same way.
    There is no option to automatically remove messages from the server for an IMAP account's Inbox mailbox with any email client such as the Mail.app.
    You can access a .Mac account as the following account types with the Mail.app.
    .Mac
    IMAP
    POP
    And as the following account types with another email client on your Mac or on another computer - a Mac or Windows PC.
    IMAP
    POP
    I access my .Mac account as a .Mac type with Mail and as an IMAP account with Outlook Express on my Windows XP notebook at work.
    A benefit of an IMAP account is the ability to keep all server stored mailboxes available and synchronized with an email client on different computers.
    If you want to access your .Mac account as a POP account with Mail will require deleting and recreating the account selecting POP as the account type instead of .Mac or IMAP.
    If you are not storing the account's Sent messages on the server with Mail, before deleting the account you need to transfer all sent messages from the account's Sent mailbox to a user created "On My Mac" location mailbox which is stored locally on the hard drive.
    When deleting an account with Mail, the account named folder at Home > Library > Mail which stores the mailboxes for the account is also deleted along with the mailboxes for the account.
    This will not affect any messages currently stored on the server in the account's Inbox mailbox.

Maybe you are looking for

  • Hp officejet 6500 e709n series wireless network connection issues

    My HP officejet 6500 e709n series all-in-one printer was working perfectly fine the last time I used it (admittedly a couple of months ago).  Now it seems like the printer thinks it is connected to the wireless network, but the computer thinks it isn

  • SQRESUS.DLL Error

    I have a visual basic application that uses odbc to connect to an oracle database. However, I when I try to connect I receive the error "Error cannot load resource file sqresus.dll" I am running windows nt 4.0 sp6 and oracle 8.1.7.5 odbc drivers. If

  • CFolder & SRM on same server that too be on same client

    Hi, We are using SRM 7.0 with PPS. In our case,both the C-folders(PLM suite-Add on component) as well as the SRM server are on the same box that too same client. So would we need to create the new RFC and Logical system for cFolders also. As we are h

  • Update Infotype - Content vanishes

    Hello, Iu2019ve got the following problem: We use a selfmade BSP-Application to update a customer-infotype. After having processed the u2018Save-Buttonu2019, I can see the new content in the infotype by using transaction SE16. About 20 minutes later,

  • InDesign CS6 opens all documents from the previous day on startup

    First of all I am on a Mac using a Mobile Account. I have no admin control over this setup. Every 2 hours or the local environment syncs with the server and saves my 'computer'. The problem is when opening InDesign in the morning to start the day hun