Hi Ken, thanks for the information.
My ultimate goal for this add-in is to automatically determine what account
to send from for composing new mail based on the current folder selected.
This is a user experience feature missing from Outlook (that Thunderbird does
automatically).
The only obstacle is getting the mail delivery location associated with an
email account (shown in the GUI). The add-in works fine if I hard code the
path-to-account information, but of course that is not ideal.
The other viable option is to match root folder names with account display
names and that is something I'd like to avoid.
Is there any way to do what I'm talking about?
"Ken Slovak - [MVP - Outlook]" wrote:
An email account doesn't have a mail store associated with it, an Outlook
profile has both accounts and one or more mail stores associated with it.
By default anything you send from any account in a profile ends up in your
default mail store for that profile.
There is a hot fix available that lets the Sent Items folder of a
non-default Exchange mailbox get items sent using the email address for that
non-default Exchange mailbox, instead of the items going to Sent Items in
the default store. That's controlled by a registry setting, but it doesn't
apply to PST files, only to Exchange mailboxes.
You can get the sending address of the item from the
MailItem.SendUsingAccount property. That might help you determine where to
route things if that's your goal.
--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm
"Kamran A" wrote in message
...
This is my first time developing an add-in for Outlook 2007. I have
successfully been able to retrieve accounts and successfully been able to
retrieve stores.
However, I see no way to correlate the two. My goal is to find what path
(or
store) the account is using to store messages in. I see no property on a
store to get an account and see no property to get a store on account.
Is there any way to do this? In the GUI it's easy enough! Is it a rule or
something? How would I find it?
Thanks for any help!