I have a VB6 application which creates and displays mail items in Outlook using Redemption's RDO. Everything works except after my application terminates the window of every mail item originally created and displayed by my application becomes unusable, i.e. I cannot send, save or print from that window.
Requested clarification: I create the items using GetDefaultFolder(olFolderDrafts).Items.Add
and display them calling the Display
method after I attached a file. The user has to send the item explicitly.
Depending on the action I get different generic messages, like "could not send mail" or "the messaging interface returned an unknown error".
I'm really desperate because I've run out of ideas.
What I've tried:
- Different logon methods:
Logon
andMAPIOBJECT
- Skipping
Logoff
- Using
GetObject
instead ofCreateObject
(for the Outlook instance) - Updating to the latest Redemption version
Some more information:
- The problem exists with Outlook 2007, but the same application works fine with Outlook 2000.
- The item is correctly saved, i.e. if I re-open it using Outlook everything works
- If I use plain Outlook objects everything works fine, too, so it must be something I'm doing wrong with Redemption.
EDIT: I downloaded OutlookSpy and after my window becomes unusable, every non-trivial action returns the error code 0x800706BA (RPC_S_SERVER_UNAVAILABLE
). I assume that somehow the connection to the Exchange server is closed for that specific mail item.
- Is that possible?
- Is there anything I can do to prevent that from happending?
More observations:
- If I keep my application in memory, opening the same mail item from Outlook opens a new window. Normally the original window would be just brought into the foreground.
- Using Outlook 2000 the window I display does not have the additional OutlookSpy buttons.
EDIT 2009-11-17: If anyone has some more suggestions I'm still interested!