Question

I'm using JvMail component to send e-mails by outlook in my application.

When sending e-mails by outlook 2013 and the outlook is closed, the new e-mail window opens normally, but when JvMail tries to send e-mail while outlook 2013 is running, I get the error: MAPI Error: (2) General MAPI Failure.

I'm using windows 8 and outlook 2013. I have tested this situation with outlook 2007 and Windows XP and works fine with the outlook 2007 open or closed.

How can I fix this? I'm working with Delphi XE3.

Obs: There is no need to post my code, because the error happens even if I create JvMail and call JvMail.SendMail(True).

Was it helpful?

Solution

After some time without seeing this, I have figured out that the problem only happens when I try to open outlook with the Delphi opened.

If I use the JvMail to open outlook when executing my application without being by delphi, the problem doesn't happen.

I have also tested trying to open outlook using report builder, Indy and JvMail. All of them don't open outlook when running my application by delphi but they work perfectly when running my application directly by the exe file.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top