OpenMsgStore and Exchange dialog

OpenMsgStore and Exchange dialog

Post by Michael Ti » Thu, 12 Mar 2009 05:34:05


I'm making a call to OpenMsgStore and Exchange.

It displays the default dialog and prompts the user for the exchange
password but does not wait for a response before returning success.

How can I force it to wait for a response from the dialog ?
 
 
 

OpenMsgStore and Exchange dialog

Post by Dmitry Str » Thu, 12 Mar 2009 13:14:13

Do you pass the handdle of the right parent window for the dialog?

--
Dmitry Streblechenko (MVP)
http://www.yqcomputer.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-

 
 
 

OpenMsgStore and Exchange dialog

Post by Michael Ti » Thu, 12 Mar 2009 20:35:46

Yes, OpenMsgStore just displays the dialog and returns immediately
(S_OK) leaving the dialog on the screen. It's very strange,
 
 
 

OpenMsgStore and Exchange dialog

Post by Michael Ti » Thu, 12 Mar 2009 21:03:12

I'm using DesktopWindow for both MAPILogonEx and OpenMsgStore.

In the case of MAPILogonEx it correctly allows me to select a profile.
In the case of OpenMsgStore, like I said it returns straight away as if
the password dialog was not modal.
 
 
 

OpenMsgStore and Exchange dialog

Post by Dmitry Str » Thu, 12 Mar 2009 23:56:04

Can you try to pass the handle of a window from your process?
Are you using multiple threads?

--
Dmitry Streblechenko (MVP)
http://www.yqcomputer.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
 
 
 

OpenMsgStore and Exchange dialog

Post by Michael Ti » Fri, 13 Mar 2009 00:45:27

I've tried passing a handle to a window in my process and that does not
make any difference.

I've initialized mapi for multi thread notifications.

This is occurring on the main thread (which also initialized mapi)

My application runs out of the system tray, so my window is never really
visible.
 
 
 

OpenMsgStore and Exchange dialog

Post by Dmitry Str » Fri, 13 Mar 2009 15:35:20

I don't know, sorry.
Does that only happen in a tray app? Have you tried a regular Windows app
with your code hooked up to, say, a button click event handler?

--
Dmitry Streblechenko (MVP)
http://www.yqcomputer.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-