我正在尝试创建一个非常简单的Web Outlook插件(使用JavaScript + HTML5 + CSS)。这是教程中描述的相同加载项。
https://docs.microsoft.com/en-us/outlook/add-ins/quick-start?tabs=visual-studio
我可以创建加载项并将其添加到Outlook 2016 Web客户端。当我打开Outlook Web客户端并使用加载项时,它可以很好地工作。
现在我正在尝试将相同的加载项添加到Windows和MAC上安装的Outlook 2016客户端。在我搜索并添加加载项的两台机器上(使用“从文件添加”选项),它会成功添加。我收到“已成功安装”消息。我甚至在“我的加载项”选项下看到它。但它没有显示在工具栏中。当我再次打开商店并检查“我的加载项”列表时,加载项将从列表中消失。这意味着它从未正确安装。
由于我是新手,我无法确定原因或调试问题。我需要对清单文件进行任何更改吗?目前我使用相同的清单文件用于Web客户端,基于Windows和mac的客户端。另外我该如何调试呢?
更新
这是我用于在Web客户端注册加载项的清单文件。我正在为Windows和mac客户端使用相同的文件。清单文件不同吗?
<?xml version="1.0" encoding="UTF-8"?>
<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/1.0"
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>771983a0-73ed-45a0-90d9-0fd546592d94</Id>
<!--Version. Updates from the store only get triggered if there is a version change. -->
<Version>1.0.0.0</Version>
<ProviderName>Amey Kale</ProviderName>
<DefaultLocale>en-US</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="My Office Add-in" />
<Description DefaultValue="My First Outlook Add-in"/>
<!-- Icon for your add-in. Used on installation screens and the add-ins dialog. -->
<IconUrl DefaultValue="https://localhost/OWA/" />
<HighResolutionIconUrl DefaultValue="https://dev.sgsuite.com/OWA/assets/hi-res-icon.png"/>
<!--If you plan to submit this add-in to the Office Store, uncomment the SupportUrl element below-->
<SupportUrl DefaultValue="https://dev.sgsuite.com/OWA/assets/hi-res-icon.png" />
<!-- 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>AppDomain1</AppDomain>
<AppDomain>AppDomain2</AppDomain>
<AppDomain>AppDomain3</AppDomain>
</AppDomains>
<!--End Basic Settings. -->
<Hosts>
<Host Name="Mailbox" />
</Hosts>
<Requirements>
<Sets>
<Set Name="Mailbox" MinVersion="1.1" />
</Sets>
</Requirements>
<FormSettings>
<Form xsi:type="ItemRead">
<DesktopSettings>
<SourceLocation DefaultValue="https://dev.sgsuite.com/OWA/index.html"/>
<RequestedHeight>250</RequestedHeight>
</DesktopSettings>
</Form>
</FormSettings>
<Permissions>ReadWriteItem</Permissions>
<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">
<Requirements>
<bt:Sets DefaultMinVersion="1.3">
<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>
<!-- 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://dev.sgsuite.com/OWA/assets/icon-16.png"/>
<bt:Image id="icon32" DefaultValue="https://dev.sgsuite.com/OWA/assets/icon-32.png"/>
<bt:Image id="icon80" DefaultValue="https://dev.sgsuite.com/OWA/assets/icon-80.png"/>
</bt:Images>
<bt:Urls>
<bt:Url id="functionFile" DefaultValue="https://dev.sgsuite.com/OWA/function-file/function-file.html"/>
<bt:Url id="messageReadTaskPaneUrl" DefaultValue="https://dev.sgsuite.com/OWA/index.html"/>
</bt:Urls>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="My Add-in Group"/>
<bt:String id="customTabLabel" DefaultValue="My Add-in Tab"/>
<bt:String id="paneReadButtonLabel" DefaultValue="Display all properties"/>
<bt:String id="paneReadSuperTipTitle" DefaultValue="Get all properties"/>
</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:LongStrings>
</Resources>
</VersionOverrides>
</OfficeApp>
但是当我从Web客户端注册它时,即使Web服务器是相同的,它也不会给我这个错误。