Office365 在Outlook的桌面版本中加载Office加载项时出现问题
我一直在为outlook mail构建office加载项。外接程序在outlook的在线版本上非常有效,在outlook移动应用程序中的手机上也非常有效。我看不出有任何理由它在Outlook 2016的桌面版本中不起同样的作用。我引用了几个示例XML文件,以确保没有遗漏任何内容 有一次,我收到一个错误,说“Office.js还没有完全加载”,但现在我甚至无法调试它 这是我的XML文件Office365 在Outlook的桌面版本中加载Office加载项时出现问题,office365,outlook-addin,office-js,Office365,Outlook Addin,Office Js,我一直在为outlook mail构建office加载项。外接程序在outlook的在线版本上非常有效,在outlook移动应用程序中的手机上也非常有效。我看不出有任何理由它在Outlook 2016的桌面版本中不起同样的作用。我引用了几个示例XML文件,以确保没有遗漏任何内容 有一次,我收到一个错误,说“Office.js还没有完全加载”,但现在我甚至无法调试它 这是我的XML文件 <?xml version="1.0" encoding="UTF-8"?> <OfficeA
<?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"
xsi:type="MailApp">
<Id>{Id}</Id>
<Version>1.0.0.0</Version>
<ProviderName>Sample Add In</ProviderName>
<DefaultLocale>en-US</DefaultLocale>
<DisplayName DefaultValue="Outlook Add In"/>
<Description DefaultValue="This app helps you work more efficiently from your email inbox."/>
<IconUrl DefaultValue="logo url"/>
<HighResolutionIconUrl DefaultValue="logo url"/>
<SupportUrl DefaultValue="support url" />
<Hosts>
<Host Name="Mailbox"/>
</Hosts>
<Requirements>
<Sets DefaultMinVersion="1.1">
<Set Name="Mailbox" MinVersion="1.1"/>
</Sets>
</Requirements>
<FormSettings>
<Form xsi:type="ItemRead">
<DesktopSettings>
<SourceLocation DefaultValue="source code"/>
<RequestedHeight>350</RequestedHeight>
</DesktopSettings>
</Form>
</FormSettings>
<Permissions>ReadItem</Permissions>
<Rule xsi:type="RuleCollection" Mode="And">
<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" />
<!-- Message read form -->
<ExtensionPoint xsi:type="MessageReadCommandSurface">
<OfficeTab id="TabDefault">
<Group id="msgReadDemoGroup">
<Label resid="groupLabel" />
<!-- Task pane button -->
<Control xsi:type="Button" id="msgReadOpenPaneButton">
<Label resid="groupLabel" />
<Supertip>
<Title resid="groupLabel" />
<Description resid="paneReadSuperTipDescription" />
</Supertip>
<Icon>
<bt:Image size="16" resid="blue-icon-32" />
<bt:Image size="32" resid="blue-icon-32" />
<bt:Image size="80" resid="blue-icon-32" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="readTaskPaneUrl" />
</Action>
</Control>
</Group>
</OfficeTab>
</ExtensionPoint>
</DesktopFormFactor>
</Host>
</Hosts>
<Resources>
<bt:Images>
<bt:Image id="blue-icon-32" DefaultValue="icon" />
</bt:Images>
<bt:Urls>
<bt:Url id="readTaskPaneUrl" DefaultValue="source code" />
</bt:Urls>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="label" />
</bt:ShortStrings>
<bt:LongStrings>
<bt:String id="paneReadSuperTipDescription" DefaultValue="long description" />
</bt:LongStrings>
</Resources>
<VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides/1.1" xsi:type="VersionOverridesV1_1">
<Requirements>
<bt:Sets DefaultMinVersion="1.3">
<bt:Set Name="Mailbox" />
</bt:Sets>
</Requirements>
<Hosts>
<Host xsi:type="MailHost">
<DesktopFormFactor>
<FunctionFile resid="functionFile" />
<!-- Message read form -->
<ExtensionPoint xsi:type="MessageReadCommandSurface">
<OfficeTab id="TabDefault">
<Group id="msgReadDemoGroup">
<Label resid="groupLabel" />
<!-- Task pane button -->
<Control xsi:type="Button" id="msgReadOpenPaneButton">
<Label resid="groupLabel" />
<Supertip>
<Title resid="groupLabel" />
<Description resid="paneReadSuperTipDescription" />
</Supertip>
<Icon>
<bt:Image size="16" resid="blue-icon-32" />
<bt:Image size="32" resid="blue-icon-32" />
<bt:Image size="80" resid="blue-icon-32" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="readTaskPaneUrl" />
</Action>
</Control>
</Group>
</OfficeTab>
</ExtensionPoint>
</DesktopFormFactor>
<MobileFormFactor>
<ExtensionPoint xsi:type="MobileMessageReadCommandSurface">
<Group id="mobileMsgRead">
<Label resid="groupLabel" />
<Control xsi:type="MobileButton" id="TaskPaneBtn">
<Label resid="groupLabel" />
<Icon xsi:type="bt:MobileIconList">
<bt:Image size="25" scale="1" resid="blue-icon-32" />
<bt:Image size="25" scale="2" resid="blue-icon-32" />
<bt:Image size="25" scale="3" resid="blue-icon-32" />
<bt:Image size="32" scale="1" resid="blue-icon-32" />
<bt:Image size="32" scale="2" resid="blue-icon-32" />
<bt:Image size="32" scale="3" resid="blue-icon-32" />
<bt:Image size="48" scale="1" resid="blue-icon-32" />
<bt:Image size="48" scale="2" resid="blue-icon-32" />
<bt:Image size="48" scale="3" resid="blue-icon-32" />
</Icon>
<Action xsi:type="ShowTaskpane">
<SourceLocation resid="readTaskPaneUrl" />
</Action>
</Control>
</Group>
</ExtensionPoint>
</MobileFormFactor>
</Host>
</Hosts>
<Resources>
<bt:Images>
<bt:Image id="blue-icon-32" DefaultValue="icon" />
</bt:Images>
<bt:Urls>
<bt:Url id="readTaskPaneUrl" DefaultValue="source code" />
</bt:Urls>
<bt:ShortStrings>
<bt:String id="groupLabel" DefaultValue="label" />
</bt:ShortStrings>
<bt:LongStrings>
<bt:String id="paneReadSuperTipDescription" DefaultValue="long description" />
</bt:LongStrings>
</Resources>
</VersionOverrides>
</VersionOverrides>
</OfficeApp>
可能是重复的,所以它正在加载,只是没有完全加载控制台中的javascript错误?如果是这样的话,你能发布你的JS吗?@NickCaruso它似乎一点也不远。它甚至没有达到我可以在我的应用程序根标记中看到加载程序的程度(~ Angular application中呈现的第一件事)。该应用程序由几个大小适中的组件组成,但我将在上面的帖子中发布main.ts文件。我甚至看不到控制台了,因为在Outlook中打开调试器时什么也没发生。@Slavavivanov我不相信它是重复的,但感谢您的引用。清单看起来是正确的。但是,如果没有与源代码的链接,我们无法重现此问题。你能不能提供源代码给我们,或者简单地复制一下这个问题?此外,您能否提供您看到的错误的屏幕截图?
import { enableProdMode } from '@angular/core';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { AppModule } from './app/app.module';
import { environment } from './environments/environment';
if (environment.production) {
enableProdMode();
}
declare let Office: any;
Office.initialize = (reason: any) => platformBrowserDynamic().bootstrapModule(AppModule);