Problem working with foldere below inbox

K

Keith

I am writing a function to process a folder that is a sub-folder of
"Inbox."
I can identify inbox and work with it, using the following code.
However, I have been unable to obtain a list of folders, and cannot figure
out how to connect to the Inbox sub-folder "MySubFolder"

Any suggestions would be helpful,

Below is the code that works
'Open or attach to Outlook
Set oApp = New Outlook.Application
Set oNameSp = oApp.GetNamespace("MAPI")

'Attach to the appropriate folders
Set oFoldMail = oNameSp.GetDefaultFolder(6) '6=Inbox

thanks

keith
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top