I am implementing COM Add-In for Outlook. I use IDTExtensibility2. I am not sure whether this is the best way of doing COM Add-Ins but I cannot change that.
This interface defines five methods: OnConnection, OnStartupComplete, OnAddInsUpdate, OnBeginShutdown, OnDisconnection.
I need to perform the following operations:
- Load configuration data from file
- Load registry data
- Start new session
- Create *.pst file
- Subscribe to Explorer events
- Connect to Internet Server to get some data
- Create menu items in the main menu
- Create a toolbar
- Add/Remove several things in Outllok (on *.pst files level)
Please advise, what I am supposed to do when?
- What I need to perform in OnConnection method?
- What is allowed only when OnStartupComplete invokes?
- What resources I need to free dispose during OnBeginShutdown / OnDisconnection?