A Microsoft Outlook email forum. Outlook Banter

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.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Making custom Outlook 2007 folders emptiable like "Deleted Items"



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old December 21st 09, 05:17 PM posted to microsoft.public.outlook.program_vba
JoeBrind17
external usenet poster
 
Posts: 1
Default Making custom Outlook 2007 folders emptiable like "Deleted Items"

I want to create a "MyDumpster" subfolder under "Inbox" and have it offer the
"Empty 'MyDumpster' Folder" option in the context menu appearing when I
right-click it in the Navigation pane. I do not want to write a "Delete
Folder" macro and bind it to a new menu button. Instead, I want the new
folder to possess something akin to an "Emptiable" property similarly to the
"Deleted Items" folder. How do I do this, please?
Ads
  #2  
Old December 22nd 09, 03:29 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Making custom Outlook 2007 folders emptiable like "Deleted Items"

Use the Application.FolderContextMenuDisplay() event. You will need to add a
CommandBarButton object to the CommandBar passed to you in that event
handler, so you will need to add a new menu entry when the event fires.

Your code then will have to iterate the folder's contents and delete
everything in the folder, then it will need to delete everything moved from
the folder to the Deleted Items folder.

There is no "emptiable" property as you seem to think.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"JoeBrind17" wrote in message
...
I want to create a "MyDumpster" subfolder under "Inbox" and have it offer
the
"Empty 'MyDumpster' Folder" option in the context menu appearing when I
right-click it in the Navigation pane. I do not want to write a "Delete
Folder" macro and bind it to a new menu button. Instead, I want the new
folder to possess something akin to an "Emptiable" property similarly to
the
"Deleted Items" folder. How do I do this, please?


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Delete Folders from Outlook 2007 "Deleted Items" Folder. [email protected] Outlook and VBA 0 December 27th 07 03:38 PM
How to Delete Folders from Outlook 2007 "Deleted Items" Folder. [email protected] Add-ins for Outlook 0 December 27th 07 03:34 PM
I have a "server failures" directory within "deleted items" geoffkmorrison Outlook - General Queries 3 August 31st 07 07:58 PM
Outlook 2003 saves all drafts in "Deleted Items" -- Can it change Tim Bresnahan Outlook - General Queries 0 September 6th 06 07:19 PM
PST views - Can I hide "Search Folders" and "Deleted Items"? Rob Outlook - General Queries 1 August 25th 06 08:41 PM


All times are GMT +1. The time now is 08:20 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.