为什么在Office Word 2016中,MenuContext无法使用?

问题描述 投票:0回答:1

我试图开发一个office-js字插件,以增强右键菜单,但当我在我的清单中添加的元素。Word不能读取访问的清单了。所以OfficeMenu对我来说是不可用的。

我可以检查什么?

非常感谢

<ExtensionPoint xsi:type="ContextMenu">
            <OfficeMenu id="ContextMenuText">
              <Control xsi:type="Menu" id="ContextMenu2">
                <Label resid="CommandGroup.Label"/>
                <Supertip>
                  <Title resid="TaskpaneButton.Label"/>
                  <Description resid="TaskpaneButton.Tooltip"/>
                </Supertip>
                <Icon>
                    <bt:Image size="16" resid="Icon.16x16"/>
                    <bt:Image size="32" resid="Icon.32x32"/>
                    <bt:Image size="80" resid="Icon.80x80"/>
                  </Icon>
                  <Items>
                    <Item id="Item1">
                      <Label resid="IdItem1"/>
                      <Supertip>
                        <Title resid="IdItem1"/>
                        <Description resid="TaskpaneButton.Label"/>
                      </Supertip>
                      <Icon>
                      <bt:Image size="16" resid="Icon.16x16"/>
                      <bt:Image size="32" resid="Icon.32x32"/>
                      <bt:Image size="80" resid="Icon.80x80"/>
                    </Icon>
                    <Action xsi:type="ShowTaskpane">
                      <TaskpaneId>ButtonId1</TaskpaneId>
                      <SourceLocation resid="Taskpane.Url"/>
                    </Action>
                  </Item>
                </Items>
              </Control>
            </OfficeMenu>
          </ExtensionPoint> ```
office-js office-addins office-js-helpers
1个回答
1
投票

好吧,我想我找到了错误的地方。

我运行的运行时调试模块,我发现,这个问题只是由于一个排版错误。

以下一行 <Label resid="CommandGroup.Label"/>指的是一个标签的命令sGroup.Label,所以我在labelname中少了S,这就是为什么模块不能正常加载的原因。

© www.soinside.com 2019 - 2024. All rights reserved.