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

Creating Top Level Folder within Outlook 2003



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old April 23rd 07, 10:05 PM posted to microsoft.public.outlook.program_vba
Adrian Butler
external usenet poster
 
Posts: 1
Default Creating Top Level Folder within Outlook 2003

Need to create a top level fodler within a users mailbox called 3 year
retention. Would like to find a way to script this for approx 6000
mailboxes, any suggestions or recommendations are appreciated


  #2  
Old April 24th 07, 02:15 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Creating Top Level Folder within Outlook 2003

When you say top level folder do you mean one just below "Mailbox" and on a
level with Inbox?

Set ol = New Outlook.Application
Set ns = ol.GetNameSpace("MAPI")
Set folder = ns.GetDefaultFolder(6) 'Inbox
Set folder2 = folder.Parent
Set folder3 = folder2.Folders.Add("3 Year Retention", 6) 'new email folder

That would work as a VBScript. If you want to create a different type of
folder use a different value from the OlDefaultFolders enumeration.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Adrian Butler" wrote in message
...
Need to create a top level fodler within a users mailbox called 3 year
retention. Would like to find a way to script this for approx 6000
mailboxes, any suggestions or recommendations are appreciated


 




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
Creating Outlook Search Folder Programatically. Elanchezhian.R Outlook and VBA 2 February 7th 07 06:09 AM
Creating Mailbox Top Level Folder with VBA Boy from Oz Outlook and VBA 2 November 24th 06 07:05 AM
Problem creating folder in Outlook Add-In. Paulo Braz Figueiredo Add-ins for Outlook 0 October 18th 06 01:31 PM
Correct way to get top-level folder of newly added store (new PST file) [email protected] Outlook and VBA 2 September 22nd 06 11:47 PM
Creating a PST file at the server level Amwendwa Outlook - General Queries 8 February 10th 06 01:01 PM


All times are GMT +1. The time now is 06:30 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.