Adding a dynamic global button to the Notes toolbar

Last week I posted an update to the Mail Rule Utilities on OpenNTF.  The primary change, as I wrote about, was to move the icon to the global toolbar in Notes.  I not only did this but I also put a condition in the logic to only be visible when certain views have focus.  One can argue if this was or was not the right thing to do in this specific case but I figure I would play around a little.  You can get the source files right from the release download on the OpenNTF site for reference.  A big advantage to moving to an Eclipse based product is adding stuff like this to the product is easy and common across all Eclipse products.  The two extensions used are basic Eclipse extensions that Lotus Notes inherits for free.

You start by declaring your action set using the org.eclipse.ui.actionSets extension in the plugin.xml:

         label="Mail Tools">
         label="Run Mail Rules">

         label="&amp;Run Mail Rules"
         tooltip="Run Mail Rules"

You then need to associate it with a view part using the org.eclipse.ui.actionSetPartAssociations extension:

<extension point="org.eclipse.ui.actionSetPartAssociations">
     <actionSetPartAssociation targetID="">
         <part id="" />
         <part id=""/>
         <part id=""/>


1 thought on “Adding a dynamic global button to the Notes toolbar

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.