none
Getting close event of outlook. RRS feed

  • Question

  •        I have the addin Expresss to close the event 
                this.FormsManager = AddinExpress.OL.ADXOlFormsManager.CurrentInstance;
                this.FormsManager.OnInitialize +=new AddinExpress.OL.ADXOlFormsManager.OnComponentInitialize_EventHandler(this.FormsManager_OnInitialize);
                this.FormsManager.Initialize(this);           
                OutlookInspectors = Application.Inspectors;
                OutlookInspectors.NewInspector += new Microsoft.Office.Interop.Outlook.InspectorsEvents_NewInspectorEventHandler(OutlookInspectors_NewInspector);
               bool cancel =false;
               Application.ItemSend += new ApplicationEvents_11_ItemSendEventHandler(Application_ItemSend(OutlookMailItem, cancel));
      But not able to close it       
    Wednesday, October 26, 2016 1:40 PM

All replies

  • Hello Jatin,

    You can handle the Quit event of the Application class which is fired when Microsoft Outlook begins to close.

    Be aware, as part of the goal to improve performance, Microsoft Office Outlook 2007 Service Pack 2 (SP2) and Microsoft Outlook 2010 include some significant changes to ensure that Outlook shuts down properly when the user attempts to close it. The Shutdown Changes for Outlook 2010 article describes the changes to Outlook 2010.

    In case if the fast shutdown feature is enabled, you can handle the Close event of the Explorer/Inspector classes to be notified when the last window is going to be closed, so the Outlook process finishes.

    See Outlook 2010 Fast Shutdown feature for more information.


    [custom.development]

    Wednesday, October 26, 2016 4:06 PM
  • Hi Jatin,

    you had mentioned that ," I have the addin Expresss to close the event "

    are you developing using Addin express?

    This forum only handles the issues regarding Outlook object model.

    if you are using Addin Express then please try to raise the issue on Addin Express Forum.

    visit the link mentioned below.

    Add-in Express™ Support Service

    Regards

    Deepak


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, October 27, 2016 9:44 AM
    Moderator
  • Deepack,

    The Outlook object model is common for all kind of applications. It doesn't matter whether you develop a VSTO or Add-in Express based add-in. Moreover, earlier I mentioned the article which describes the required steps for handling the Close event correctly, see Outlook 2010 Fast Shutdown feature for more information.


    [custom.development]

    Thursday, October 27, 2016 10:44 AM