I'm tasked to develop an Outlook add-in that is 'always open' when reading emails.
The requirements for the plugin is:
The idea is that the user has a TaskPane or pinned panel which is visible when reading an email. The context is always the active email that is to be manipulated or forwarded by the add-in.
I've spent a great deal of time trying to make the "SupportsPinning" work, but without success. According to the documentation, this feature only works in Outlook 2016.
I've stumbled upon the TaskPaneApp, which apparently should be 'always open'? but it seems that its support is limited?
I found the TaskPane samples on Github, but in Outlook it's declared that the Addin is a MailApp with a TaskPane instead of being a TaskPaneApp. Is this because Outlook doesn't support TaskPaneApp's?
The manifest is as follows:
<?xml version="1.0" encoding="UTF-8"?>
<!--Created:ce44715c-8c4e-446b-879c-ea9ebe0f09c8-->
<OfficeApp xmlns="http://schemas.microsoft.com/office/appforoffice/1.1"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:bt="http://schemas.microsoft.com/office/officeappbasictypes/1.0"
xmlns:mailappor="http://schemas.microsoft.com/office/mailappversionoverrides"
xsi:type="MailApp">
<!-- Begin Basic Settings: Add-in metadata, used for all versions of Office unless override provided. -->
<!-- IMPORTANT! Id must be unique for your add-in, if you reuse this manifest ensure that you change this id to a new GUID. -->
<Id>77ad5285-3a98-4387-a4b3-c70c6e12cd6a</Id>
<!--Version. Updates from the store only get triggered if there is a version change. -->
<Version>1.0.0.0</Version>
<ProviderName>AutoIT A/S</ProviderName>
<DefaultLocale>da-dk</DefaultLocale>
<!-- The display name of your add-in. Used on the store and various places of the Office UI such as the add-ins dialog. -->
<DisplayName DefaultValue="AutoDesktop CRM Outlook Add-in" />
<Description DefaultValue="AutoIT CRM Add-in for added integration with AutoDesktop"/>
<IconUrl DefaultValue="https://localhost:44329/Images/icon64.png"/>
<SupportUrl DefaultValue="https://www.autoit.dk/support" />
<!-- Domains that will be allowed when navigating. For example, if you use ShowTaskpane and then have an href link, navigation will only be allowed if the domain is on this list. -->
<AppDomains>
<AppDomain>autodesktop.dk</AppDomain>
<AppDomain>autoit.dk</AppDomain>
</AppDomains>
<!--End Basic Settings. -->
<Hosts>
<Host Name="Mailbox" />
</Hosts>
<Requirements>
<Sets>
<Set Name="Mailbox" MinVersion="1.5" />
</Sets>
</Requirements>
<FormSettings>
<Form xsi:type="ItemRead">
<DesktopSettings>
<SourceLocation DefaultValue="https://localhost:44329/MessageRead.html"/>
<RequestedHeight>250</RequestedHeight>
</DesktopSettings>
</Form>
</FormSettings>
<Permissions>ReadWriteMailbox</Permissions>
<!-- Activationg rules. (Specify WHEN the ADDIN is activated) -->
<Rule xsi:type="RuleCollection" Mode="Or">
<Rule xsi:type="ItemIs" ItemType="Message" FormType="Read" />
</Rule>
<DisableEntityHighlighting>false</DisableEntityHighlighting>
<VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides"
xsi:type="VersionOverridesV1_0">
<!--<Description resid="residAppDescription" />-->
<Requirements>
<bt:Sets DefaultMinVersion="1.5">
<bt:Set Name="Mailbox" />
</bt:Sets>
</Requirements>
<Hosts>
<Host xsi:type="MailHost">
<!-- Definition of the ADDIN Ribbon buttons-->
<DesktopFormFactor>
<!-- Location of the Functions that UI-less buttons can trigger (ExecuteFunction Actions). -->
<FunctionFile resid="functionFile" />
<!-- Message Read -->
<ExtensionPoint xsi:type="MessageReadCommandSurface">
<!-- Use the default tab of the ExtensionPoint or create your own with <CustomTab id="myTab"> -->
<OfficeTab id="TabDefault">
<!-- Up to 6 Groups added per Tab -->
<Group id="msgReadGroup">
<Label resid="groupLabel" />
<!-- Launch the add-in : task pane button -->
<Control xsi:type="Button" id="msgReadOpenPaneButton">
<Label resid="paneReadButtonLabel" />
<Supertip>
<Title resid="paneReadSuperTipTitle" />
<Description resid="paneReadSuperTipDescription" />
</Supertip>
<Icon>
<bt:Image size="16" resid="icon16" />
<bt:Image size="32" resid="icon32" />
<bt:Image size="80" resid="icon80" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="messageReadTaskPaneUrl" />
</Action>
</Control>
<Control xsi:type="Button" id="testMsgReadOpenPaneButton">
<Label resid="testPaneReadButtonLabel" />
<Supertip>
<Title resid="testPaneReadSuperTipTitle" />
<Description resid="testPaneReadSuperTipDescription" />
</Supertip>
<Icon>
<bt:Image size="16" resid="icon16" />
<bt:Image size="32" resid="icon32" />
<bt:Image size="80" resid="icon80" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="testMRWebServiceCalls" />
</Action>
</Control>
<!-- Go to http://aka.ms/ButtonCommands to learn how to add more Controls: ExecuteFunction and Menu -->
</Group>
</OfficeTab>
</ExtensionPoint>
<!-- Go to http://aka.ms/ExtensionPointsCommands to learn how to add more Extension Points: MessageRead, AppointmentOrganizer, AppointmentAttendee -->
</DesktopFormFactor>
</Host>
</Hosts>
<Resources>
<bt:Images>
<bt:Image id="icon16" DefaultValue="https://localhost:44329/Images/icon16.png"/>
<bt:Image id="icon32" DefaultValue="https://localhost:44329/Images/icon32.png"/>
<bt:Image id="icon80" DefaultValue="https://localhost:44329/Images/icon80.png"/>
</bt:Images>
<bt:Urls>
<bt:Url id="functionFile" DefaultValue="https://localhost:44329/Functions/FunctionFile.html"/>
<bt:Url id="messageReadTaskPaneUrl" DefaultValue="https://localhost:44329/MessageRead.html"/>
<bt:Url id="testMRWebServiceCalls" DefaultValue="https://localhost:44329/testMessageReadWebServiceCalls.html"/>
</bt:Urls>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="ADT's Super-Duber 'Not-an-Easi'r-clone' Add-in"/>
<bt:String id="customTabLabel" DefaultValue="My Add-in Tab"/>
<bt:String id="paneReadButtonLabel" DefaultValue="ADT - Display all email properties"/>
<bt:String id="paneReadSuperTipTitle" DefaultValue="ADT - Gets all the email properties"/>
<bt:String id="testPaneReadButtonLabel" DefaultValue="TEST - Other button"/>
<bt:String id="testPaneReadSuperTipTitle" DefaultValue="TEST - This button will do some stuff aswell"/>
</bt:ShortStrings>
<bt:LongStrings>
<bt:String id="paneReadSuperTipDescription" DefaultValue="ADT - Opens a pane displaying all available properties. This is an example of a button that opens a task pane."/>
<bt:String id="testPaneReadSuperTipDescription" DefaultValue="TEST - Does some stuff. Hopefully it works. Might delete later"/>
</bt:LongStrings>
</Resources>
<VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides/1.1"
xsi:type="VersionOverridesV1_1">
<!--<Description resid="residDescription" />-->
<Requirements>
<!-- add information on requirements -->
<bt:Sets DefaultMinVersion="1.5"><!-- <<<< -->
<bt:Set Name="Mailbox" />
</bt:Sets>
</Requirements>
<Hosts>
<Host xsi:type="MailHost">
<DesktopFormFactor>
<!-- Location of the Functions that UI-less buttons can trigger (ExecuteFunction Actions). -->
<FunctionFile resid="functionFile" />
<!-- Message Read -->
<ExtensionPoint xsi:type="MessageReadCommandSurface">
<!-- Use the default tab of the ExtensionPoint or create your own with <CustomTab id="myTab"> -->
<OfficeTab id="TabDefault">
<!-- Up to 6 Groups added per Tab -->
<Group id="msgReadGroup">
<Label resid="groupLabel" />
<!-- Launch the add-in : task pane button -->
<Control xsi:type="Button" id="msgReadOpenPaneButton">
<Label resid="paneReadButtonLabel" />
<Supertip>
<Title resid="paneReadSuperTipTitle" />
<Description resid="paneReadSuperTipDescription" />
</Supertip>
<Icon>
<bt:Image size="16" resid="icon16" />
<bt:Image size="32" resid="icon32" />
<bt:Image size="80" resid="icon80" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="messageReadTaskPaneUrl" />
</Action>
</Control>
<Control xsi:type="Button" id="testMsgReadOpenPaneButton">
<Label resid="testPaneReadButtonLabel" />
<Supertip>
<Title resid="testPaneReadSuperTipTitle" />
<Description resid="testPaneReadSuperTipDescription" />
</Supertip>
<Icon>
<bt:Image size="16" resid="icon16" />
<bt:Image size="32" resid="icon32" />
<bt:Image size="80" resid="icon80" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="testMRWebServiceCalls" />
<SupportsPinning>true</SupportsPinning>
</Action>
</Control>
<!-- Go to http://aka.ms/ButtonCommands to learn how to add more Controls: ExecuteFunction and Menu -->
</Group>
</OfficeTab>
</ExtensionPoint>
<!-- Go to http://aka.ms/ExtensionPointsCommands to learn how to add more Extension Points: MessageRead, AppointmentOrganizer, AppointmentAttendee -->
</DesktopFormFactor>
</Host>
<Host xsi:type="MailHost">
<MobileFormFactor>
<FunctionFile resid="functionFile" />
<ExtensionPoint xsi:type="MobileMessageReadCommandSurface">
<Group id="mobileMsgRead">
<Label resid="groupLabel" />
<Control xsi:type="MobileButton" id="msgReadOpenPaneButton">
<Label resid="paneReadButtonLabel" />
<Icon xsi:type="bt:MobileIconList">
<bt:Image size="25" scale="1" resid="mIcon25" />
<bt:Image size="25" scale="2" resid="mIcon25" />
<bt:Image size="25" scale="3" resid="mIcon25" />
<bt:Image size="32" scale="1" resid="mIcon32" />
<bt:Image size="32" scale="2" resid="mIcon32" />
<bt:Image size="32" scale="3" resid="mIcon32" />
<bt:Image size="48" scale="1" resid="mIcon48" />
<bt:Image size="48" scale="2" resid="mIcon48" />
<bt:Image size="48" scale="3" resid="mIcon48" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="mobileMessageReadTaskPaneUrl"/>
</Action>
</Control>
</Group>
</ExtensionPoint>
</MobileFormFactor>
</Host>
</Hosts>
<Resources>
<bt:Images>
<bt:Image id="icon16" DefaultValue="https://localhost:44329/Images/icon16.png"/>
<bt:Image id="icon32" DefaultValue="https://localhost:44329/Images/icon32.png"/>
<bt:Image id="icon80" DefaultValue="https://localhost:44329/Images/icon80.png"/>
<bt:Image id="mIcon25" DefaultValue="https://localhost:44329/Images/Icon-25.png"/>
<bt:Image id="mIcon32" DefaultValue="https://localhost:44329/Images/Icon-32.png"/>
<bt:Image id="mIcon48" DefaultValue="https://localhost:44329/Images/Icon-48.png"/>
</bt:Images>
<bt:Urls>
<bt:Url id="functionFile" DefaultValue="https://localhost:44329/Functions/FunctionFile.html"/>
<bt:Url id="messageReadTaskPaneUrl" DefaultValue="https://localhost:44329/MessageRead.html"/>
<bt:Url id="mobileMessageReadTaskPaneUrl" DefaultValue="https://localhost:44329/MessageRead.html"/>
<bt:Url id="testMRWebServiceCalls" DefaultValue="https://localhost:44329/testMessageReadWebServiceCalls.html"/>
</bt:Urls>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="ADT's Super-Duber Add-in"/>
<bt:String id="customTabLabel" DefaultValue="My Add-in Tab"/>
<bt:String id="paneReadButtonLabel" DefaultValue="Display all email properties"/>
<bt:String id="paneReadSuperTipTitle" DefaultValue="Gets all the email properties"/>
<bt:String id="testPaneReadButtonLabel" DefaultValue="Other button"/>
<bt:String id="testPaneReadSuperTipTitle" DefaultValue="This button will do some stuff aswell"/>
</bt:ShortStrings>
<bt:LongStrings>
<bt:String id="paneReadSuperTipDescription" DefaultValue="Opens a pane displaying all available properties. This is an example of a button that opens a task pane."/>
<bt:String id="testPaneReadSuperTipDescription" DefaultValue="Does some stuff. Hopefully it works. Might delete later"/>
</bt:LongStrings>
</Resources>
</VersionOverrides>
</VersionOverrides>
While investigating the Yeomen generated code for an add-in with SupportsPinning enabled, i noticed that it didn't have a MobileFormFactor in the Manifest.
Deleting this entry from my manifest resulted in the Pinning function to show up and work as expected !