msoControlSplitButtonPopup
Thursday, December 9, 2004, 02:29 - Programming
Today I continued with my Outlook plugin in .NET project. All required features are now present and there even is a configuration screen to edit the settings and store them in the Windows Registry. So now I have two buttons in the Outlook standard bar: one to perform the actual action and one to display the configuration screen.

I thought it would be cool to combine these into a so called msoControlSplitButtonPopup, just like e.g. the New Mail button in Outlook or the font color selection in Word: when you press the button the default action occurs but when you click the little down arrow on the right hand side of the button, a menu pops up and you can select other actions.

After a lot of experimenting and googling I unfortunately came to the conclusion that this is not possible. This specific button type is only available to Microsoft itself, they did not make it available through the addin API. The customer doesn't mind because he is already happy with the functionality I offered him, but it would have been very cool to have it under a single split button popup....

I'm still thinking about what other possible MS Office addin I could make, because I am very enthousiastic about it and would love to play around with this material some more. I'm also interested to play around with .NET Remoting so perhaps something challenging will come up involving a client-server setup.....


Outlook plugin in .NET
Friday, December 3, 2004, 14:32 - Programming
Yesterday at work I created an MS Outlook plugin using Microsoft Visual Studio .NET! The basics are incredibly simple, just create a new addin project and select which Office application you want to create the addin for.
Then came the harder part: adding a button to the toolbar. I found an example, but somewhere along the way it stopped removing the buttons when I shut down Outlook, so now I have over half a dozen of stale buttons that cannot be deleted anymore :(
I finally found out that you can also add buttons non-permanently. So everytime Outlook shuts down, this button is removed again. Just what I want!

Then came the actual business: connecting to a database, fetching data from it, creating new emails with attachments and marking the emails as sent in the database. In my case the emails need to remain in the Drafts folder as they must manually be signed with PGP , but you could also send them immediately. Then you could also add a timer to the project and have emails sent comletely automatically as long as an instance of Outlook is open....

The more I work with .NET, the more respect I gain for it... In the early days I was skeptical about MS duplicating Java in their own way: limiting a cross-platform environment to Windows only. But now that I have worked with it some more, and also came across some limitations of Java, I think they did a pretty good job! For Windows application development it definitely is very decent.



Back