views:

12

answers:

1

I have an outlook add-in which runs only on the first startup of Outlook, at which point it creates a toolbox and adds it to Outlook's command bar. I used this approach rather than creating a temporary UI on each startup because I want the user's decisions about the control to be persistent; if the user disables the control or moves it, it should stay moved.

However, when uninstalling the application, the UI stays behind, even though the dll is unregistered and deleted. CUrrently, the only idea I have for fixing this issue is for the add-in dll (or a separate dll) to, after uninstall, remain behind, be triggered one more in uninstall mode, and remove the toolbar the next time Outlook starts up.

There are a few issues with this approach:

  1. I am not sure, short of unregistering and registering the dll, how to force the dll I made to run again the next time outlook starts.
  2. I am not sure if my thoughts on an approach are even a good idea.
  3. This whole thing strikes me as hacky.

What would be the best way to remove such a UI after an uninstall?

A: 

Well, I'll post the real answer to this, which is what everyone says to do, but is not what I wanted to hear. The correct solution is to just make it a temporary toolbar and save/load the positioning data myself by hand (e.g. something like this).

Brian