How to tell what the default delivery location is for Outlook 2003

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How can you tell what the default delivery location is for Outlook 2003 without going through the interface? Is it in the registry or in a file? Need to be able to access it programatically.

Ryan
 
I believe that will only get you a handle on the default inbox. I want to be able to determine if their default delivery location is a pst or mailbox and if a pst what the path to the pst is.
 
The elegant way would be to use use CDO 1.21 to determine what type of store the folder belongs to by enumerating the Session.Inforstore collection and comparing each store's EntryID with the Parent.StoreID of the Inbox. The ProviderName will tell you whether it's Exchange, PST or something else.

The brute force method would be to get the Parent.StoreID itself -- if it's a .pst file, the path is embedded in the binary ID. You can use Outlook Spy to see what I mean; I don't have any sample code handy to extract it.

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook Programming: Jumpstart
for Administrators, Power Users, and Developers
 
Back
Top