System.MessageStore.Folders Property

A collection of System.MessageStore.Folder objects.

Note   Objects of type System.MessageStore.Folder can only be accessed through the Folders collection. This collection is a member of System.MessageStore.

This property is read-only.

Syntax

propVal = System.MessageStore.Folders()

  

Parameters

  • collFolders [out]
    A collection of System.MessageStore.Folder objects.

Remarks

Folders exposes the Windows Mail (formerly Outlook Express) Local Folders collection. Subfolders and their content (such as messages) are not exposed.

Note  See the Messages Collection for information about accessing the Messages in a particular folder.

Examples

The following example demonstrates how to use the Folders Collection and the System.MessageStore.Folder properties of each folder.

// Create a Folders Collection and assign it to the variable collFolders.
var collFolders = System.MessageStore.Folders; 

// Get the total number of folders in the Folders Collection and assign it to the variable iCount.
var iCount = collFolders.count;

// Select the folder from position 0 in the Folders Collection and assign it to the variable oFolder.
var oFolder = collFolders.item(0);

// Get the name of the folder and assign it to the variable strName.
var strName = oFolder.name;

// Get the number of messages in the folder and assign it to the variable iMsgCount.
var iMsgCount = oFolder.messageCount;

// Get the number of unread messages in the folder and assign it to the variable iUnreadMsgCount.
var iUnreadMsgCount = oFolder.unreadMessageCount;

// Get the folder's Messages Collection and assign it to the variable collMsgs.
var collMsgs = oFolder.Messages;

Requirements

Minimum supported client Windows Vista
Minimum supported server Windows Server 2008
IDL Sidebar.idl
DLL Sidebar.Exe version 1.00 or later

See Also

Reference

count

item

System.MessageStore

System.MessageStore.Folder

Messages

System.MessageStore.Message

 

 

Send comments about this topic to Microsoft

Build date: 2/24/2010

Build type: SDK