12-28-2009 11:33 PM
I would like to delete messages on Mailbox and Handheld on BIS programmatically. Can this be achieved? For extra information, I'm working on BIS, not BES. The Email Settings is already configured (Synchronize deleted items between this mailbox and my device is checked), and I'm using a popular mail service which is Yahoo. I can do this manually in the standard BlackBerry Messages application, where you can select a message, click Delete, and you'll be presented with options like Delete on Mailbox and Handheld, and it works.
Programmatically, I've tried these (and they are not working) :
1. Folder deleteMessage method. This only deletes the message on the handheld, not on the mailbox.
2. Using special subject text like <$removeondelivery>. This is not working too (I think this is for BES only).
Any help or insight is greatly appreciated, thanks in advance.
12-29-2009 12:43 AM
If you traverse through all the Folders and delete the messages, it should be get deleted.
Have you tried the method,
public boolean deleteMessage(Message msg, boolean forceDeleteSaved)
Parameters: msg - Message to delete from this folder. forceDeleteSaved - If the message is saved, force it's deletion. Returns: True if the message is successfully deleted; otherwise, false (for example, if the message does not exist in this folder).
Since: BlackBerry API 4.0.2
12-29-2009 01:10 AM
12-29-2009 01:28 AM
Programatically we can delete from the store of the device, not on the web.
Suggestion, not tried, there are few custom apps I have seen for accessing yahoo or gmail on mobile, this indicated we could access the pop and smtp servers from outside and get the mails from those services and delete them.
08-18-2010 07:34 PM - edited 08-18-2010 07:36 PM
Go to Messages--Options--Email Reconciliation. Select your Yahoo email account and make sure "Delete On:" is set to either "Mailbox & Handheld" or "Prompt".
EDIT--I just realized this may not address your issue. I'm not really sure. Hopefully it does.
09-19-2011 01:18 AM - edited 09-19-2011 06:31 AM
Hi, in my app i need same requirement , delete all text messages programatically at a time...plz send me a snip of code if you solve the problem thanks in advance