1
votes

We have develop Add-in Manifest.xml file for Custom tab with Groups. We have refer below urls to develop it. https://docs.microsoft.com/en-us/office/dev/add-ins/reference/manifest/customtab#customtab-example https://docs.microsoft.com/en-us/office/dev/add-ins/reference/manifest/group

Develop Manifest.xml file is working fine on office Online 365 but when we import same on Desktop Excel 365 its not working.

            <!--Control. It can be of type "Button" or "Menu" -->
            <Control xsi:type="Button" id="Contoso.FunctionButton">
            <!--Label for your button. resid must point to a ShortString resource -->
              <Label resid="Contoso.FunctionButton.Label" />
              <Tooltip resid="Contoso.FunctionButton.Tooltip"/>
              <Supertip>
                 <!--ToolTip title. resid must point to a ShortString resource -->
                <Title resid="Contoso.FunctionButton.Label" />
                 <!--ToolTip description. resid must point to a LongString resource -->
                <Description resid="Contoso.FunctionButton.Tooltip" />
              </Supertip>
              <Icon>
                <bt:Image size="16" resid="Contoso.FunctionButton.Icon" />
                <bt:Image size="32" resid="Contoso.FunctionButton.Icon" />
                <bt:Image size="80" resid="Contoso.FunctionButton.Icon" />
              </Icon>
              <!--This is what happens when the command is triggered (E.g. click on the Ribbon). Supported actions are ExecuteFuncion or ShowTaskpane-->
              <!--Look at the FunctionFile.html page for reference on how to implement the function -->
              <Action xsi:type="ShowTaskpane">
              <!--Name of the function to call. This function needs to exist in the global DOM namespace of the function file-->
              <TaskpaneId>ButtonId1</TaskpaneId>
                <SourceLocation resid="Contoso.FunctionButton.Url" />
              </Action>
            </Control>

            <Control xsi:type="Button" id="Contoso.TaskpaneButton">
              <Label resid="Contoso.TaskpaneButton.Label" />
              <Tooltip resid="Contoso.TaskpaneButton.Tooltip" />
              <Supertip>
                <Title resid="Contoso.TaskpaneButton.Label" />
                <Description resid="Contoso.TaskpaneButton.Tooltip" />
              </Supertip>
              <Icon>
                <bt:Image size="16" resid="Contoso.TaskpaneButton.Icon" />
                <bt:Image size="32" resid="Contoso.TaskpaneButton.Icon" />
                <bt:Image size="80" resid="Contoso.TaskpaneButton.Icon" />
              </Icon>
              <Action xsi:type="ShowTaskpane">
                <TaskpaneId>Button2Id1</TaskpaneId>
                 <!--Provide a url resource id for the location that will be displayed on the task pane -->
                <SourceLocation resid="Contoso.Taskpane1.Url" />
              </Action>
            </Control>
        <!-- Menu example -->


          </Group>
          <Group id="Contoso.Tab1.Group2">
             <!--Label for your group. resid must point to a ShortString resource -->
            <Label resid="Contoso.Tab1.GroupLabel" />
            <Icon>
            <!-- Sample Todo: Each size needs its own icon resource or it will look distorted when resized -->
            <!--Icons. Required sizes 16,31,80, optional 20, 24, 40, 48, 64. Strongly recommended to provide all sizes for great UX -->
            <!--Use PNG icons and remember that all URLs on the resources section must use HTTPS -->
              <bt:Image size="16" resid="Contoso.TaskpaneButton.Icon" />
              <bt:Image size="32" resid="Contoso.TaskpaneButton.Icon" />
              <bt:Image size="80" resid="Contoso.TaskpaneButton.Icon" />
            </Icon>

            <!--Control. It can be of type "Button" or "Menu" -->
            <Control xsi:type="Button" id="Contoso.FunctionButton">
            <!--Label for your button. resid must point to a ShortString resource -->
              <Label resid="Contoso.FunctionButton.Label" />
              <Tooltip resid="Contoso.FunctionButton.Tooltip"/>
              <Supertip>
                 <!--ToolTip title. resid must point to a ShortString resource -->
                <Title resid="Contoso.FunctionButton.Label" />
                 <!--ToolTip description. resid must point to a LongString resource -->
                <Description resid="Contoso.FunctionButton.Tooltip" />
              </Supertip>
              <Icon>
                <bt:Image size="16" resid="Contoso.FunctionButton.Icon" />
                <bt:Image size="32" resid="Contoso.FunctionButton.Icon" />
                <bt:Image size="80" resid="Contoso.FunctionButton.Icon" />
              </Icon>
              <!--This is what happens when the command is triggered (E.g. click on the Ribbon). Supported actions are ExecuteFuncion or ShowTaskpane-->
              <!--Look at the FunctionFile.html page for reference on how to implement the function -->
              <Action xsi:type="ShowTaskpane">
              <!--Name of the function to call. This function needs to exist in the global DOM namespace of the function file-->
              <TaskpaneId>ButtonId1</TaskpaneId>
                <SourceLocation resid="Contoso.FunctionButton.Url" />
              </Action>
            </Control>

            <Control xsi:type="Button" id="Contoso.TaskpaneButton">
              <Label resid="Contoso.TaskpaneButton.Label" />
              <Tooltip resid="Contoso.TaskpaneButton.Tooltip" />
              <Supertip>
                <Title resid="Contoso.TaskpaneButton.Label" />
                <Description resid="Contoso.TaskpaneButton.Tooltip" />
              </Supertip>
              <Icon>
                <bt:Image size="16" resid="Contoso.TaskpaneButton.Icon" />
                <bt:Image size="32" resid="Contoso.TaskpaneButton.Icon" />
                <bt:Image size="80" resid="Contoso.TaskpaneButton.Icon" />
              </Icon>
              <Action xsi:type="ShowTaskpane">
                <TaskpaneId>Button2Id1</TaskpaneId>
                 <!--Provide a url resource id for the location that will be displayed on the task pane -->
                <SourceLocation resid="Contoso.Taskpane1.Url" />
              </Action>
            </Control>
        <!-- Menu example -->


          </Group>

          <!-- Label of your tab -->
          <!-- If validating with XSD it needs to be at the end, we might change this before release -->
          <Label resid="Contoso.Tab1.TabLabel" />
        </CustomTab>
      </ExtensionPoint>

Please help us to solve it.

1
Please provide more details than just "not working". What goes wrong and what are the steps leading up to it?Rick Kirkham
@Sameer, Please provide more information to suggest anything. Please mention if you face any issue around Teams.Abhijit
When we used <CustomTab> tag with multiple <Group> tag, Add-in manifest file is not read in add-in on Desktop.Sameer Shaikh

1 Answers

2
votes

Basing on:

I'd hazard a guess that a problem in question is that you see corresponding item in the menu in Office Online, but do not see it in desktop version. If so, you can try next steps:

  • remove the space in the id attribute of CustomTab: <CustomTab id="ContosoTab">

Also, you can check the manifest of ScriptLab. It is a good example of a working manifest. https://github.com/OfficeDev/script-lab/tree/master/manifests