Hello all.
We have a rather ugly situation. We have an application that uses MAPISendMail() to open the composer window from the default email client on a users PC (for now lets assume this email client is Outlook).
As soon as Outlook's "composer" window (or whatever it's called) is up if I can't return to my FWH app because this window has made it in effect MODAL. I have to either finish entering the mail and send it, or cancel it to be able to return to my FWH app.
You can imagine this isn't going well with users who don't expect to be forced to send the email before being able to get back to our app. Usually the might want to look up additional info they might want to add to the email.
So the million dollar question is: can MAPISendMail() be instructed to behave MODLESS instead of forcing the calling app to remain MODAL till it's done?
I noticed (in mapi.c) that the call to mapisendmail uses GetActiveWindow() as one of it's parameters. From our app I tried doing a SetActiveWindow() to Outlook's hWnd (which I already know and I'm positive is the right one) but either SetActiveWindow() is broken and doesn't actually set the current active window (a subsecuent call to GetActiveWindow() shows that my FWH app remains the current active window, not Outlook).
I tried calling SetForegroundWindow() and BringWindowToFront() but that makes no difference either.
Any help in how to make MAPISendMail() behave nicely is very much appreciated!
Luis Krause.