views:

336

answers:

0

I'm creating an Outlook 2007 add-in using Visual Studio 2008 and C#.

I have my custom task pane along with my usercontrol docked to the bottom of the main Outlook window. I'm trying to implement auto-hide on this taskpane so that it minimizes to a certain size when the mouse leaves it. My problem arises in the fact that custom task panes have very very few events, namely, DockChanged and VisibilityChanged. Nothing about gaining or losing focus, or mouse entering and exiting.

Another problem is that the mouse entering/exiting my pane doesn't fire events on my usercontrol. I'm assuming that this is because my user control has a flash control which fills my usercontrol. My workaround was to use the GotFocus andLostFocus events from the flash control. This works decently EXCEPT for the fact that if the user resizes the task pane the LostFocus event fires which causes the task pane to hide - yet still be resizing.

So...how would I go about implementing an auto-hide pane in Outlook 2007 using C# around these restrictions?