2

I have created excel add-ins using office.js and react-fabric UI. I have created manifest and validated using command: npx --ignore-existing office-addin-manifest validate manifest.xml And it looks good with no issue. When I am uploading manifest in desktop excel, it showing below error on excel. Although its not blocking any add ins functionality but it giving wrong impression to user. PFA SS of error: "Error loading add-ins" error

On click of Ribbon buttons its working as expected but on excel bottom it showing error on manifest load.

PSB is my manifest file and please help to identify the cause of this error as we need to release application to our customer but because of this error its causing blocker for our releasae.

    <?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:ov="http://schemas.microsoft.com/office/taskpaneappversionoverrides" xsi:type="TaskPaneApp">
    <!-- 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>565764A6-0F6E-4D98-A1EF-39B86F13D169</Id>
    <!--Version. Updates from the store only get triggered if there is a version change. -->
    <Version>1.0.0.0</Version>
    <ProviderName>Office Developer Education Team.</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="Contoso Data Importer" />
    <Description DefaultValue="Get started with extracting your data. Add in a dataset to your workbook."/>
    <!-- Icon for your add-in. Used on installation screens and the add-ins dialog. -->
    <IconUrl DefaultValue="https://localhost:8060/assests/icon-32.png" />
    <HighResolutionIconUrl DefaultValue="https://localhost:8060/assests/icon-32.png"/>
    <!--If you plan to submit this add-in to the Office Store, uncomment the SupportUrl element below-->
    <!--<SupportUrl DefaultValue="[Insert the URL of a page that provides support information for the app]">-->
    <!-- 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. -->
    <!-- <SupportUrl DefaultValue="https://www.contoso.com/help"/> -->
    <AppDomains>
        <AppDomain>https://localhost:8060</AppDomain>
    </AppDomains>
    <!--End Basic Settings. -->
    <!--Begin TaskPane Mode integration. This section is used if there are no VersionOverrides or if the Office client version does not support add-in commands. -->
    <Hosts>
        <Host Name="Workbook" />
    </Hosts>
    <Requirements>
        <Sets DefaultMinVersion="1.1">
            <Set Name="SharedRuntime" MinVersion="1.1"/>
        </Sets>
    </Requirements>
    <DefaultSettings>
        <SourceLocation DefaultValue="https://localhost:8060/#/index.html" />
    </DefaultSettings>
    <!-- End TaskPane Mode integration.  -->
    <Permissions>ReadWriteDocument</Permissions>
    <!-- Begin Add-in Commands Mode integration. -->
    <VersionOverrides xmlns="http://schemas.microsoft.com/office/taskpaneappversionoverrides" xsi:type="VersionOverridesV1_0">
        <!-- The Hosts node is required. -->
        <Hosts>
            <!-- Each host can have a different set of commands. -->
            <!-- Excel host is Workbook, Word host is Document, and PowerPoint host is Presentation. -->
            <!-- Make sure the hosts you override match the hosts declared in the top section of the manifest. -->
            <Host xsi:type="Workbook">
                <Runtimes>
                    <Runtime resid="ContosoAddin.Url" lifetime="long" />
                </Runtimes>
                <AllFormFactors>
                    <ExtensionPoint xsi:type="CustomFunctions">
                        <Script>
                            <SourceLocation resid="ContosoAddin.Url"/>
                        </Script>
                        <Page>
                            <SourceLocation resid="ContosoAddin.Url"/>
                        </Page>
                        <Metadata>
                            <SourceLocation resid="ContosoAddin.Url"/>
                        </Metadata>
                        <Namespace resid="Functions.Namespace"/>
                    </ExtensionPoint>
                </AllFormFactors>
                <!-- Form factor. Currently only DesktopFormFactor is supported. -->
                <DesktopFormFactor>
                    <!--"This code enables a customizable message to be displayed when the add-in is loaded successfully upon individual install."-->
                    <GetStarted>
                        <!-- Title of the Getting Started callout. resid points to a ShortString resource -->
                        <Title resid="GetStarted.Title"/>
                        <!-- Description of the Getting Started callout. resid points to a LongString resource -->
                        <Description resid="GetStarted.Description"/>
                        <!-- Point to a url resource which details how the add-in should be used. -->
                        <LearnMoreUrl resid="GetStarted.LearnMoreUrl"/>
                    </GetStarted>
                    <!-- Function file is a HTML page that includes the JavaScript where functions for ExecuteAction will be called.
            Think of the FunctionFile as the code behind ExecuteFunction. -->
                    <FunctionFile resid="ContosoAddin.Url" />
                    <!-- PrimaryCommandSurface is the main Office Ribbon. -->
                    <ExtensionPoint xsi:type="PrimaryCommandSurface">
                        <!-- Use OfficeTab to extend an existing Tab. Use CustomTab to create a new tab. -->
                        <CustomTab id="ShareTime">
                            <Group id="LoginGroup">
                                <Label resid="LoginGroup.Label"/>
                                <Icon>
                                    <bt:Image size="16" resid="LGButton.Icon"/>
                                    <bt:Image size="32" resid="LGButton.Icon"/>
                                    <bt:Image size="80" resid="LGButton.Icon"/>
                                </Icon>
                                <Control xsi:type="Button" id="BtnLoginService">
                                    <Label resid="BtnLoginService.Label" />
                                    <Supertip>
                                        <!-- ToolTip title. resid must point to a ShortString resource. -->
                                        <Title resid="BtnLoginService.Label" />
                                        <!-- ToolTip description. resid must point to a LongString resource. -->
                                        <Description resid="BtnLoginService.Tooltip" />
                                    </Supertip>
                                    <Icon>
                                        <bt:Image size="16" resid="LGButton.Icon"/>
                                        <bt:Image size="32" resid="LGButton.Icon"/>
                                        <bt:Image size="80" resid="LGButton.Icon"/>
                                    </Icon>
                                    <!-- This is what happens when the command is triggered (E.g. click on the Ribbon). Supported actions are ExecuteFunction or ShowTaskpane. -->
                                    <Action xsi:type="ExecuteFunction">
                                        <FunctionName>btnloginservice</FunctionName>
                                    </Action> 
                                </Control>
                                <Control xsi:type="Button" id="BtnLogoutService">
                                    <Label resid="BtnLogoutService.Label" />
                                    <Supertip>
                                        <!-- ToolTip title. resid must point to a ShortString resource. -->
                                        <Title resid="BtnLogoutService.Label" />
                                        <!-- ToolTip description. resid must point to a LongString resource. -->
                                        <Description resid="BtnLogoutService.Tooltip" />
                                    </Supertip>
                                    <Icon>
                                        <bt:Image size="16" resid="SignOutButton.Icon"/>
                                        <bt:Image size="32" resid="SignOutButton.Icon"/>
                                        <bt:Image size="80" resid="SignOutButton.Icon"/>
                                    </Icon>
                                    <!-- This is what happens when the command is triggered (E.g. click on the Ribbon). Supported actions are ExecuteFunction or ShowTaskpane. -->
                                    <Action xsi:type="ExecuteFunction">
                                        <FunctionName>btnlogoutservice</FunctionName>
                                    </Action>
                                    <Enabled>false</Enabled>
                                </Control>
                            </Group>
                            <Label resid="CommandsGroup.Label"/>
                        </CustomTab>
                    </ExtensionPoint>
                </DesktopFormFactor>
            </Host>
        </Hosts>
        <!-- You can use resources across hosts and form factors. -->
        <Resources>
            <bt:Images>             
                <bt:Image id="LGButton.Icon" DefaultValue="https://localhost:8060/assests/log_in.png" />
                <bt:Image id="SignOutButton.Icon" DefaultValue="https://localhost:8060/assests/log_out.png" />
            </bt:Images>
            <bt:Urls>       
                <bt:Url id="ContosoAddin.Url" DefaultValue="https://localhost:8060/#/index.html"/>
                <bt:Url id="LGButton.Url" DefaultValue="https://localhost:8060/#/login" />
                <bt:Url id="GetStarted.LearnMoreUrl" DefaultValue="https://go.microsoft.com/fwlink/?LinkId=276812" />
            </bt:Urls>
            <!-- ShortStrings max characters==125. -->
            <bt:ShortStrings>       
                <bt:String id="GetStarted.Title" DefaultValue="Contoso Data Importer add-in has loaded successfully." />
                <bt:String id="Functions.Namespace" DefaultValue="CONTOSO"/>
                <bt:String id="BtnLoginService.Label" DefaultValue="Sign in"/>
                <bt:String id="BtnLogoutService.Label" DefaultValue="Sign out"/>
                <bt:String id='StartupGroup.Label' DefaultValue='Contoso Data Importer Services'/>
                <bt:String id='LoginGroup.Label' DefaultValue='Authentication'/>
                <bt:String id='FeedbackGroup.Label' DefaultValue='Let us know'/>
                <bt:String id="CommandsGroup.Label" DefaultValue="CONTOSO DATA"/>
            </bt:ShortStrings>
            <!-- LongStrings max characters==250. -->
            <bt:LongStrings>
                <bt:String id="TaskpaneButton.Tooltip" DefaultValue="Get files stored on OneDrive" />
                <bt:String id="GetStarted.Description" DefaultValue="Get going by opening CONTOSO importer TAB on the Ribbon." />
                <bt:String id="BtnLoginService.Tooltip" DefaultValue="Please sign in "/>
                <bt:String id="BtnLogoutService.Tooltip" DefaultValue="Please sign out"/>
            </bt:LongStrings>
        </Resources>
    </VersionOverrides>
    <!-- End Add-in Commands Mode integration. -->
</OfficeApp>
sagar
  • 464
  • 4
  • 13
  • Do you get the error on Office on the web or Office for Mac? Or is it only on Windows? Also, by "desktop Excel" do you mean one-time purchase or the Microsoft 365 subscription version? – Rick Kirkham Oct 11 '21 at 17:51
  • The "Error loading add-ins" may not be related with your add-in, instead it may be caused by add-ins in cache but cannot be loaded anymore. You may can clear the office cache on Windows (%LOCALAPPDATA%\Microsoft\Office\16.0\Wef\) to see if the error still exists. – xiaochun Oct 12 '21 at 01:55
  • @Rick Kirkham, Gets error only on office on Windows desktop excel, Microsoft 365 subscription version. Not getting on office on web. – sagar Oct 12 '21 at 08:14
  • @xiaochun-Microsoft, yes tried with cache clear as well but still same issue. – sagar Oct 12 '21 at 08:15
  • @Rick Kirkham, Please let me know if I am missing anything. Thanks in advance. – sagar Oct 12 '21 at 17:10
  • When something works on Office on the web, but not on desktop that might be a bug. I suggest that you create an issue at the [office-js](https://github.com/OfficeDev/office-js/issues/new/choose) repo. – Rick Kirkham Oct 12 '21 at 17:38
  • Solved by commenting tag. Not sure what is the purpose of tag but by commenting this tag that error is no longer. – sagar Nov 03 '21 at 08:58

1 Answers1

0

By commenting below tag from manifest file that manifest upload error is resolved.

<!-- <AllFormFactors>
                <ExtensionPoint xsi:type="CustomFunctions">
                    <Script>
                        <SourceLocation resid="ContosoAddin.Url"/>
                    </Script>
                    <Page>
                        <SourceLocation resid="ContosoAddin.Url"/>
                    </Page>
                    <Metadata>
                        <SourceLocation resid="ContosoAddin.Url"/>
                    </Metadata>
                    <Namespace resid="Functions.Namespace"/>
                </ExtensionPoint>
            </AllFormFactors> -->
sagar
  • 464
  • 4
  • 13