Switch view to Folder List

R

Rob Nicholson

I'm trying to write some macros to help people using public folder
favourites on Outlook 2003 - which are a real pain to get to: switch to
folder list view, scroll down, open lots of windows etc.

I know enough about the Outlook API to get a MAPIFolder and do
Outlook.ActiveExplorer.SelectFolder Folder. This works if the "Folder List"
view is selected first. Doesn't work if the "Mailbox" or "Calendar" view is
applied (or any other view).

How do you change the current view to the "Folder List" from VBA? I suspect
it's some method against ActiveExplorer but the problem with not doing
Outlook API stuff very often, is that I don't know the entire model.

Thanks, Rob.
 
R

Rob Nicholson

How do you change the current view to the "Folder List" from VBA? I
suspect it's some method against ActiveExplorer but the problem with not
doing Outlook API stuff very often, is that I don't know the entire model.

Okay, got this bit sorted:

Application.ActiveExplorer.ShowPane olFolderList, True
Application.ActiveExplorer.SelectFolder Folder

However, whilst the focus is on the Favourites folder, it's often way down
the bottom. Is there a way to scroll down the folder list to force an item
into view?

Thanks, Rob.
 
S

Sue Mosher [MVP-Outlook]

You cannot scroll the folder list display. What you can do is set ActiveExplorer.CurrentFolder to show a particular folder, which should highlight it also in the folder list:

Set Application.ActiveExplorer.CurrentFolder = Folder

There is no SelectFolder method.
 

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