Add Method (Folders Collection)

Add Method (Folders Collection)

See Also         Example         Applies To

Creates a new folder in the Folders collection, and returns the new folder as a MAPIFolder object.

Syntax

objFolders.Add(Name, [Type])

objFolders   Required. An expression that returns a Folders object.

Name   Required String. The display name for the new folder.

Type   Optional Long. The Outlook folder type for the new folder. If the folder type is not specified, the new folder will default to the same type as the folder in which it is created. Can be one of the following OlDefaultFolders constants: olFolderCalendar(9), olFolderContacts(10), olFolderDrafts(16), olFolderInbox(6), olFolderJournal(11), olFolderNotes(12), or olFolderTasks(13). (The constants olFolderDeletedItems(3), olFolderOutbox(6), and olFolderSentMail(5) cannot be specified for this argument.)