我正试图通过在清单文件中进行以下更改来启用outlookwebaddin for mobile,但安装失败并抛出以下错误。
错误消息:
清单文件:
<?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">
<Id>3a734653-a3ab-4021-ad93-8df9fce4e1e9</Id>
<Version>1.0.0.0</Version>
<ProviderName>ABCTech</ProviderName>
<DefaultLocale>en-US</DefaultLocale>
<DisplayName DefaultValue="testMobile" />
<Description DefaultValue="testMobile"/>
<IconUrl DefaultValue="~remoteAppUrl/Images/icon64.png"/>
<SupportUrl DefaultValue="http://www.abctech.com" />
<AppDomains>
<AppDomain>AppDomain1</AppDomain>
<AppDomain>AppDomain2</AppDomain>
<AppDomain>AppDomain3</AppDomain>
</AppDomains>
<Hosts>
<Host Name="Mailbox" />
</Hosts>
<Requirements>
<Sets>
<Set Name="Mailbox" MinVersion="1.1" />
</Sets>
</Requirements>
<FormSettings>
<Form xsi:type="ItemRead">
<DesktopSettings>
<SourceLocation DefaultValue="~remoteAppUrl/MessageRead.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>
<FunctionFile resid="functionFile" />
<ExtensionPoint xsi:type="MessageReadCommandSurface">
<OfficeTab id="TabDefault">
<Group id="msgReadGroup">
<Label resid="groupLabel" />
<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>
</Group>
</OfficeTab>
</ExtensionPoint>
</DesktopFormFactor>
</Host>
</Hosts>
<Resources>
<bt:Images>
<bt:Image id="icon16" DefaultValue="~remoteAppUrl/Images/icon16.png"/>
<bt:Image id="icon32" DefaultValue="~remoteAppUrl/Images/icon32.png"/>
<bt:Image id="icon80" DefaultValue="~remoteAppUrl/Images/icon80.png"/>
</bt:Images>
<bt:Urls>
<bt:Url id="functionFile" DefaultValue="~remoteAppUrl/Functions/FunctionFile.html"/>
<bt:Url id="messageReadTaskPaneUrl" DefaultValue="~remoteAppUrl/MessageRead.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 xmlns="http://schemas.microsoft.com/office/mailappversionoverrides/1.1" xsi:type="VersionOverridesV1_1">
<Hosts>
<Host xsi:type="MailHost">
<MobileFormFactor>
<FunctionFile resid="functionFile" />
<ExtensionPoint xsi:type="MobileMessageReadCommandSurface">
<Group id="mobileMsgRead">
<Label resid="groupLabel"/>
<Control id="mblRestButton" xsi:type="MobileButton">
<Label resid="mblButtonLabel"/>
<Icon xsi:type="bt:MobileIconList">
<bt:Image size="25" scale="1" resid="green-icon-32" />
<bt:Image size="25" scale="2" resid="green-icon-32" />
<bt:Image size="25" scale="3" resid="green-icon-32" />
<bt:Image size="32" scale="1" resid="green-icon-32" />
<bt:Image size="32" scale="2" resid="green-icon-32" />
<bt:Image size="32" scale="3" resid="green-icon-32" />
<bt:Image size="48" scale="1" resid="green-icon-32" />
<bt:Image size="48" scale="2" resid="green-icon-32" />
<bt:Image size="48" scale="3" resid="green-icon-32" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="restMobileTaskPaneUrl"/>
</Action>
</Control>
</Group>
</ExtensionPoint>
</MobileFormFactor>
</Host>
</Hosts>
<Resources>
<bt:Images>
<bt:Image id="green-icon-16" DefaultValue="~remoteAppUrl/Images/icon16.png"/>
<bt:Image id="green-icon-32" DefaultValue="~remoteAppUrl/Images/icon32.png"/>
<bt:Image id="green-icon-80" DefaultValue="~remoteAppUrl/Images/icon80.png"/>
</bt:Images>
<bt:Urls>
<bt:Url id="functionFile" DefaultValue="~remoteAppUrl/FunctionFile/Functions.html"/>
<bt:Url id="restMobileTaskPaneUrl" DefaultValue="~remoteAppUrl/home.html"/>
</bt:Urls>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="Add-in Demo"/>
<bt:String id="mblButtonLabel" DefaultValue="Test REST Calls"/>
</bt:ShortStrings>
</Resources>
</VersionOverrides>
</VersionOverrides>
</OfficeApp>
但是相同的清单文件适用于桌面版本。上面的清单遵循与桌面版本的生产清单相同的结构。
这就是
link
接下来我添加了mobileFormFactor元素,用于支持移动设备。
------------------------------编辑后------------------------------------
以下是MobileFormFactor之前需要添加的缺失部分
<DesktopFormFactor>
<FunctionFile resid="functionFile" />
<ExtensionPoint xsi:type="MessageReadCommandSurface">
<OfficeTab id="TabDefault">
<Group id="msgReadGroup">
<Label resid="groupLabel"/>
<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>
</Group>
</OfficeTab>
</ExtensionPoint>
</DesktopFormFactor>