How to set flag to Flags.Flag.DELETED if POP3 doesn't support flags?

Hi,
I'm having problems setting message states. Could someone help me please?
According to http://www.inf.fu-berlin.de/lehre/SS01/swp/A-D/JavaMail/docs/sundocs/com/sun/mail/pop3/POP3Folder.html, POP3 protocol doesn't support any permanent flags. If this is true, that would mean that I can't do a message.setFlag(Flags.Flag.DELETED,true) to messages that I have retrieved.
Nor would I be able to check if a message is SEEN, ANSWERED, DRAFT, FLAGGED, RECENT or any USER states either. How do I go about this? I need to retrieve the messages and then set them to DELETED.
Cheers,
Callista

I have tried the IMAP and its is working fine, and it is working fine.
Also I have set the DELETED flag and make a close for folder then session and it is also working without calling the Expunge
for (int i = 0; i < messages.length; i++)
     if (!messages.isSet(Flags.Flag.SEEN))
     messages[i].setFlag(Flags.Flag.DELETED, true);
folder.close(true);
store.close();

Similar Messages

  • How to set the conditions for item deletion approval workflow?

    Hi,
    I have created approval workflow for item modifications ie, when user try to modify an item, it will send a mail to Project Manager. For that I set the conditions in Change the behavior of the overall task: 1. When the task process starts 2 . When the task
     process completes .
    Change the behavior of the single task: 1.when a task is Pending.
    [I followed this https://www.nothingbutsharepoint.com/sites/eusp/Pages/5-Steps-to-Enhance-SharePoint-2010-Approval-Workflow.aspx ]
    My Requirement is that I want to set this same workflow for the scenario: when the user deletes an item it will send a mail (intimation mail for item deletion) to Project Manager. here i dont want to send modification mails when user deletes an item.
    When user modifies an item: 1. intimation mail, 2. Approve/Reject mail 3. intimation for approval / rejection mail.
    When user deletes an item: 1. intimation mail.
    How can we set it in one approval workflow?? where i have to set the condition for sending either item modification mails or deletion mail.
    Thanks,
    Praveen ji

    Hi,
    According to your post, my understanding is that you wanted to start approval workflow when item deleted.
    You should first make some changes to trigger the workflow when you delete the item.
    You can use the Event Receiver to achieve it.
    In order to trigger workflow on item delete you need to create event receivers and from event receiver call the workflow already attached with list.
    http://ravendra.wordpress.com/sharepoint-workflow-on-list-item-delete/
    You can also create custom action to start the workflow, you can refer to the following article, then modify the workflow as your need.
    http://blogs.sharepoint911.com/blogs/jennifer/Lists/Posts/Post.aspx?ID=50
    Thanks & Regards,
    Jason
    Jason Guo
    TechNet Community Support

  • Just received my air and want to know in mail how to set it up to also delete from the hotmail server when I delete in mail.

    Please advise

    The options for removing messages from the server after being downloaded with a POP account are as follows:
    Right away.
    After one day.
    After one week.
    After one month.
    When moved from Inbox.
    This is available with the account settings at Mail > Preferences > Accounts. Select the account.  Under the Advanced tab for the account preferences at Remove copy from server after retrieving a message. This must be selected along with When moved from Inbox. When selecting a message for deletion, the message is moved to the account's Trash mailbox.

  • How can I change my username or delete my profile on Apple Support Communities

    I no longer use it, and it is causing my name to appear in Google search results even though I have my name set to "private" under my settings.
    Also, how can I change my username?

    Your profile will always be there; you cannot delete it, but you can delete all entries or set them so nothing will show but your user name. Just go to your page and click on "edit profile and privacy".
    As for your username: unfortunately, that cannot be changed. You can read many other discussions regarding this subject if you check "more like this" in the right column.

  • HOW TO SET DELETION FLAG TO SERVICE ENTRY SHEET ?

    Dear Experts,
    Can anybody explain how to set deletion flag to Service entry sheet created ?
    Service Entry sheet has been accepted and saved, i want to set deletion flag to the Service Entry sheet.
    Thanks in Advance

    Hi,
    Go to ML85 and give your service entry sheet no in Entry sheet data and select "cancel release" check box and give the corresponding release code and execute and save. The release gets cancelled.
    The other way is go to ML81N and give your Po and service entry sheet and click on the icon "cancel release" (reverse arrow mark) give the corresponding release code for cancellation and save. Now the service entry sheet will go to "No acceptance" mode. again go to the change mode and select the line item and delete it by clicking on delete icon.
    regards,
    Kannaiah Naidu

  • How to set the flag of the mail when I read it for POP3

    HI,
    All
    I know that POP3 does not support the flags. As per my knowledge the only flag POP3 supports is the DELETED. if i am not wrong.
    Now what i have to do is when i fetch the mails programmatically and once i read that I want to mark that mail as read in the yahoo also. means when i reterieve the mails through my client from the yahoo mail and next time when I Open the yahoo account the mail that i have retrieve must be seen as read rather than unread.
    Yahoo uses the POP3 Server for the incoming mails the same thing also happens with outlook you can find that outlook also uses POP3 as the incoming mail server and when we reterieve the mails from the yahoo using the outlook by some way Outlook marks the mails on the yahoo server as read the same thing I have to do for my client Program using the POP3 server.
    If Outlook does it dispite of the POP3 server there must be some way to do the same thing for the POP3 server using the Java Mail Api.I dont know how to do that thing and mark the mails as read once I fetch them.
    Any Help is appriciated,
    Rahul.

    I have tried to access the content of the message using the my program to fetch the mail but still Yahoo does not mark it as the read in its web interface.
    so I want to know how to do that. and also want to know that when you are doing same thing for the outlook then it mark it as a read on the Yahoo web mail interface so I want to know how do they do it means how Outlook mark it as a read mail on the yahoo server despite of the POP3 server.
    If anybody knows how outlook does that than we can do same using the Java mail Api.
    Regards,
    Rahul

  • How to set acknowledgement flag in asynchronous message

    Hello,
    I just read in the documenation that it is possible to request acknowlegment messages by setting an "acknowledgement tag" in the request message.
    My question now is how to set this acknowledgement tag and which rules I have to follow? Do you have any more information on this topic? I see the flags in "ReliableMessaging" but not sure how to set them.
    Thank you.
    Edited by: Florian Guppenberger on Dec 2, 2009 5:16 PM

    Hi,
    For idoc check this links
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f6d2d790-0201-0010-9382-b50b499b3fbe
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f6d2d790-0201-0010-9382-b50b499b3fbe
    I don't think it is possible for Proxy.
    Regards
    Ramesh

  • How to flag a material for deletion?

    Hi All,
    Any FM or transaction that I can use to flag a material for deletion?
    Thanks in advance.

    <b>FYI</b>
    BAPI_MATERIAL_DELETE           Flag Material for Deletion                  
    MALU                           Update Program: Set Deletion Flag Mat.      
    MATERIAL_UPDATE_LVORM          Update changed deletion flags in material mas
                                                                                    DPRL                 Change Material When Profile Deleted      
    MBAD                 Delete Material Documents                 
    MM06                 Flag Material for Deletion                
    MM16                 Schedule Material for Deletion            
    MM70                 Sel. Materials Flagged for Deletion       
    MMDE                 Delete All Materials                      
    PPRL                 Change Material When Profile Deleted      
    Tip: You can see the Package =<b>M*</b> to find out all MM related object in SE37,se93 as well as in SE38.
    Hope this’ll give you idea!!
    <b>Pl... award the points.</b>
    Good luck
    Thanks
    Saquib Khan
    "Some are wise and some are otherwise"

  • Find flagged process orders for deletion

    Hi all ,
    How do i find flagged process orders for deletion ?
    i need report or t-code

    Hello,
    Try with t-code COOISPI. In selection,Put material no and system status(sel. at header level) as DLFL
    and also check  "with deeltion flag indicator"
    Check with result and revert.
    Regards,

  • Iphoto deletes events when adding events from flagged photos

    Dear community,
    Whenever I use flagged photos, previous events get deleted. I don't know whether this is because the photos can only be in one event at a time, or that this is erroneous behaviour.
    In my logic, there should be possibility for as much events as you deem possible, yet it is mind boggling, that you don't have an automatic option, that makes you put photos in two events. Also it is mind numbing that you can't just copy & paste the pictures anywhere you like. You can paste in albums, but not into events.
    You have an option to "Create event from flagged photos", yet not an option to add photos to an existing event, you must flag them first.
    Then there is the sudden discomfort of brain pain, when you find out the previous events you've created stopped seizing to exist, and you have to sift through 500 photos, just to find 3 photos you've flagged in the creation of a previous event. Which defeats the purpose of creating them.
    The albums work good for this purpose, yet I want to be able to pin albums to the back board, where the events are. Or have events that will not disappear, may contain doubles with other events, or/and aren't restricted to copying into them. It would save a lot of time, to just CMD + C, CMD + V.

    You're confusing Events and Albums.
    In my logic, there should be possibility for as much events as you deem possible, yet it is mind boggling, that you don't have an automatic option, that makes you put photos in two events
    A photo in two Events is using twice the disk space. An album just references the photo in the Library and can be in as many albums as you like while wasting no disk space.
    You have an option to "Create event from flagged photos", yet not an option to add photos to an existing event, you must flag them first.
    Eh, you have to flag photos first before you can create an Event from them too...
    Then there is the sudden discomfort of brain pain, when you find out the previous events you've created stopped seizing to exist, and you have to sift through 500 photos, just to find 3 photos you've flagged in the creation of a previous event. Which defeats the purpose of creating them.
    Flagging photos does not delete Events. Emptying an Event deletes them.
    You can't have what you want.

  • When I flag an email with IOS 7 on my iPad 4 and delete the email the number of flags stay even though I have no flagged emails. I am up to 8 flags.

    When I flag an email with IOS 7 on my iPad 4 and delete the email the number of flags stay even though I have no flagged emails. I am up to 8 flags.

    Reset the device:
    Press and hold the Sleep/Wake button and the Home button together for at least ten seconds, until the Apple logo appears. DONT CONNECT YOUR DEVICE TO A COMPUTER

  • How can I set my Iphone 4s to delete hotmail from phone but NOT server at home?

    I can't seem to figure out how to set phone so that I can delete messages (hotmail) from phone but have them remain on server (home computer)?  I've had to recently delete and then re set my hotmail account and when I did this, I seem to have lost the ability to delete from phone and save on home computer.  thanks

    You're using an IMAP account.  Not sure if you can set up hotmail as a POP account.

  • How can I set up a rule to delete all messages older than 6 months left in Apple Mail's main inbox?

    How can I set up a rule to delete all messages older than 6 months left in Apple Mail's main inbox?
    I have created other rules to move some of my daily messages into specific folders and I don't wish to auto-delete those.
    Just the general stuff that keeps piling up in my me.com main email box.  Mail such as FB announcements and other low priority stuff I want to look at before deleting but don't want to keep longer than a week or month.
    TIA
    thokitts

    Thanks, but I am looking for a more automated solution than hand marking emails as junk. I might as well move them to the trash myself.
    Again, these are emails I want to receive and quickly read, but not keep longer than a week or month or so. By setting a rule to toss any older than 30 days back then my Mail program (and thus my hard drive) won't be wasting so much space. For example, currently I have over 6000 read messages, with their attachments, in my main email box. I'd rather not have to physically attend to sorting the one I don't want out.
    The one I do keep for other reasons get moved into other folders.
    It seems this should be possible.
    thokitts

  • How to Set "delete from hub and server" for each account

    How can I set "delete from hub and server" differently for each account?
    I have 3 emails (2 shared, 1 personal).
    the personal is a 'hotmail' account which has device set to 'sync email', 'push', and 'Use SSL'.
    it will only sync one way (from desktop to device).
    I cannot set the global setting on the device to "delete from Hub and server" without affecting all accounts.
    I do not want to have to confirm delete on every item.
    previous to the 10.3 update this was not an issue.
    am i missing something? or is this another step backwards?

    The only other way would be to set it to prompt every time you get an email. Yeah, I know that defeats the purpose.. I guess in this aspect it is a step back

  • How to set auto delete option for old messages

    Hi All,
    Can any one help me on how to set auto delete option for mails older than 15 days from my Z10.
    James Kurian

    There is no such option in BB 10.
    However, you can achieve a similar result by setting your email sync timeframe to 14 days (the closest option).
    If you are using an ActiveSync account (such as Hotmail, Outlook.com), go to Settings > Accounts > select the account. Tap advanced at the bottom of the screen. Scroll to the very bottom, tap Sync Timeframe and set to 14 days.
    If you are using an IMAP account (such as Gmail or GMX), you will have to delete, then re-add your account.  The Sync Time frame is only avaialble during setup for these accounts.  When adding, tap advanced at the bottom of the screen and set the Sync Timeframe.
    Hope this helps.

Maybe you are looking for

  • I NEED HELP! IM GOING INSANE!

    *My iPod touch has a passcode on it and it recently stopped functioning. Whenever I click the home or power button it shows a picture saying to connect to iTunes. But everytime I try to connect it tells me it can't because I have a passcode and need

  • Safari and Photo Gallery

    When browsing with Safari, clicking on a picture (for example; in AOL News) sends you to "Photo Gallery" for more pictures. The "Photo Gallery" is blank where pictures would normally show. All other pictures, u-tube videos, etc. in Safari work fine -

  • Need to reinstall iTunes from the Canadian Website

    I just purchased a new iPad from the USA and followed the instructions to install iTunes but from the US site. Now I tried to use my canadian credit card to buy apps and it won't let me, only US CCs will be accepted. Can I reinstall iTunes?

  • An error occurred when I tried to install iTunes in my Win7 PC

    Hi everyone I have bought my iPhone4 for recently and decided to download iTunes. However, during the installation, I found a error message stated that An error occurred during the installation of assembly 'Microsoft.VC80,version="8.0.52727.4053",typ

  • Period Change in MM

    Dear Gurus, I am trying to change the period indicator mater master data, as we want the period to be open for the whole year. which is June-July but the system is not letting me select the Fiscal year variant. The message says "Fiscal year variant r