Question

Hello i use MAPI API in Visual studio 2010.

when i use some operation in my custom MAPI class and my some few operations completed after when end program execution(debug mode) then outlook close automatically.

create session flag as below

MAPI_EXTENDED | MAPI_USE_DEFAULT | MAPI_NEW_SESSION

how to stop close outlook automatically ?

Était-ce utile?

La solution

Outlook will close when either all references to OOM objects are released or when a user closes the last Outlook window 9even if there are still references to Outlook objects). There is nothing you can do about that. The only workaround is to avoid using OOM and/or avoid keeping MAPI/Outlook objects referenced for any prolonged periods of time.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top