How to specify a particular inbox folder?

  • Thread starter Thread starter Richard Lewis Haggard
  • Start date Start date
R

Richard Lewis Haggard

Here's a real easy one. I'm trying to re-enable the display of email as it
comes it if it is being delivered to a particular mail folder but I've
forgotten how to do that. I've got the system to recognize when email
arrives to the default folder, but that's not the right one. The folder I
actually want is Inbox\CTSx Team. The folder I'm actually getting is Inbox.

My macro looks something like this:

Private WithEvents CTSxEmail as Outlook.Items

Private Sub Application_Startup
Set CTSxEmail = Application.Session.GetDefaultFolder(
olFolderInbox).Items
End Sub
 
To get a non-default folder, you need to walk the folder hierarchy using the Folders collections or use a function that does that for you. See http://www.outlookcode.com/d/code/getfolder.htm
--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Am Mon, 3 Apr 2006 11:39:00 -0400 schrieb Richard Lewis Haggard:

Set CTSxEmail = Application.Session.GetDefaultFolder(
olFolderInbox).Folders("CTSx Team").Items
 
Back
Top