Christophe Delhorbe
Posts: 4
Joined: 2008-09-24
|
Hi,
Let's say we have a plugin that transforms the attachment of mails when they are sent.
We have hooked the code on the itemSend event and everything works fine when the attachment is small.
We have a WPF modal dialog box to show the progress of the processing and once again, this works fine.
But when the attachment gets bigger, the processing time gets longer and everything is not so fine any longer.
As we have a modal dialog box, it seems that all Outlook waits for it to finish, no button responds to the user actions.
Is there an easy way to block the sending of the mail while we process it, and not block the rest of Outlook? Shall we use another event, or prevent outlook from sending the mail and sending it ourself when we're ready to do so (cancel the mail in itemSend, store it somewhere, process the attachement, send)?
Thanks for your help,
Christophe |
|
Eugene Astafiev
Guest
|
Hi Christophe,
Outlook is not a thread safe application. So we don't recommend to run any secondary threads in Outlook. |
|
Christophe Delhorbe
Posts: 4
Joined: 2008-09-24
|
Hi Eugeune,
I thought that I could use Outlook in a mutlithreaded manner as long as I was careful. Indeed WPF or Swing are not thread safe, that doesn't mean I can't have other thread do other things. But if you say so...
Anyway, since I can read an email while I'm receiving or sending some other ones, I thought there could be a way to proceed my attachments whithout preventing the user to read his other mails.
Best regards,
Christophe |
|
Eugene Astafiev
Guest
|
Hi Christophe,
We don't recommend to run any secondary threads in Outlook if you interfere with the Outlook Object Model. |
|