![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
I have a plugin which creates a folder that I only want to exist during the
time Outlook is running, so I've been experimenting with various ways to delete this folder. Couple questions, 1) Using MAPIFolder.Delete() seems to work every time, but the folder ends up in the Deleted Items folder...is there a way through the OOM to bypass Deleted Items when deleting a folder? 2) Using Redemption's RDOFolder.Delete() is kind of hit or miss. What I've noticed is that sometimes, right after creating the folder, I can delete it, but most often when caling this method, I get a MAPI_E_EXTENDED_ERROR (ErrorCode=-2147221223, Message="Error in IMAPIFolder: ![]() MAPI_E_EXTENDED_ERROR") . If I keep trying to delete this folder (i have a test button calling the delete method), it will eventually work after about a minute or so. Could this be the result of some kind of Exchange synchronization holding onto the folder? What is the best way to delete a folder? sample code follows for the RDODelete call I'm using: public bool DeleteArchiveSearchFolder(string sArchiveFolder) { if (!_IsValid() || sArchiveFolder == null) return false; // Have to find out if the thing is already here RDOFolders fIPMFolders = m_DefaultMsgStore.IPMRootFolder.Folders; foreach (RDOFolder f in fIPMFolders) { if (f.Name.Equals(sArchiveFolder, StringComparison.CurrentCultureIgnoreCase)) { f.Delete(); return true; } } return false; } |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Outlook Macro to delete email from Sent Folder and Delete Folder | Vishal | Outlook and VBA | 3 | February 24th 07 04:52 AM |
How do I delete an add-in | Peter Day | Outlook - Installation | 0 | February 14th 07 02:42 PM |
Cant delete | Mike | Outlook - Using Contacts | 1 | July 26th 06 10:02 AM |
How to Really Delete Sent items? | [email protected] | Outlook - General Queries | 5 | May 2nd 06 06:59 AM |
can not delete | ALROL | Outlook Express | 1 | February 27th 06 03:36 PM |