Shared mailbox and sent event

Add-in Express™ Support Service
That's what is more important than anything else

Shared mailbox and sent event
Shared mailbox and sent event 
Karim




Posts: 153
Joined: 2006-01-02
Hi Andrei,

I have another case for my topic :
https://www.add-in-express.com/forum/read.php?PAGEN_1=1&a=&FID=1&TID=13015#nav_start


A customer uses Outlook 2010 with Exchange 2010. A shared mailbox is attached to his Outlook-Profile and he's able to send mails from this address.
I changed the sent items behaviour via registry (DelegateSentItemsStyle), which ensures that e-mails sent from the shared mailbox address end up in the 'Sent Items' folder of the shared mailbox instead of the personal one.
in this case how how can capture sent event ?

Karim
Posted 24 Mar, 2015 10:56:08 Top
Andrei Smolin


Add-in Express team


Posts: 14094
Joined: 2006-05-11
Karim,

I suppose you talk about getting am email right after it gets sent. If so, you can retrieve the target folder via MailItem.SaveSentMessageFolder and connect to the ItemAdd event of the target folder's Items collection.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 25 Mar, 2015 01:48:38 Top
Karim




Posts: 153
Joined: 2006-01-02
Hi Andrei,
I found the solution !
in my code i replace for the the delivery store :
objStore := IMail.SendUsingAccount.DeliveryStore;
by
objStore := IMail.SaveSentMessageFolder.Store;
And now it works in all the case !

Thanks for your excellent support !

Karim
Posted 25 Mar, 2015 04:04:01 Top
Andrei Smolin


Add-in Express team


Posts: 14094
Joined: 2006-05-11
Great!

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 25 Mar, 2015 04:08:08 Top