<Menu> (RibbonDiffXml)

应用到: CRM 2016 on-prem, CRM Online

指定用于显示弹出菜单的容器。

语法

<Menu
 Id="String"
 MaxWidth="String" 
>
 <MenuSection />
</Menu>

属性和元素

The following table lists the attributes, child elements, and parent elements.

属性

Attribute Description Type Usage

Id

指定功能区元素的定义的唯一标识符。强烈建议的命名约定是使用句点分隔名称的各个部分,如:[解决方案标识符].[实体].[功能区].[函数].[元素名称]。例如:MyISV.account.form.SendToOtherSystem.Button。

Use the {!EntityLogicalName} token in the Id attribute when you define a ribbon element that will be used for multiple entities. This inserts the entity logical name into the Id value to make sure that the Id value is globally unique.

For example, if you use MyISV.{!EntityLogicalName}.form.SendToOtherSystem.Button with the account entity, the Id will be MyISV.account.form.SendToOtherSystem.Button. For the contact entity, the Id will be MyISV.contact.form.SendToOtherSystem.Button.

重要

If you don’t set a globally unique Id value, the ribbon might not display.

String

Required

MaxWidth

The maximum width in pixels.

String

Optional

子元素

Element Description

<MenuSection> (RibbonDiffXml)

指定用于划分菜单的部分。菜单部分可包含一个标题和多个控件。

父元素

Element Description

<CommandUIDefinition> (RibbonDiffXml)

指定要包含在 CustomAction 元素中的可见 Ribbon 元素。

<ComboBox> (RibbonDiffXml)

不建议:通过单击或键入指定用于选择值的列表。

<FlyoutAnchor> (RibbonDiffXml)

指定带向下箭头的用于打开菜单的按钮。

<DropDown> (RibbonDiffXml)

不建议:通过单击指定用于选择值的列表。

<MRUSplitButton> (RibbonDiffXml)

不建议:指定用于显示最近使用的项的拆分按钮控件。

<SplitButton> (RibbonDiffXml)

指定同时用作按钮和菜单的控件。

元素信息

XPath

//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/Menu |
//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/ComboBox/Menu |
//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/Menu/MenuSection/Controls/FlyoutAnchor/Menu |
//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/DropDown/Menu |
//Controls/DropDown/Menu |
//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/MRUSplitButton/Menu |
//Controls/MRUSplitButton/Menu |
//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/SplitButton/Menu |
//Controls/SplitButton/Menu

Schema Name

MenuType

Validation File

RibbonWSS.xsd

Can be Empty

No

另请参阅

其他资源

Ribbon XML reference
自定义命令和功能区

Microsoft Dynamics CRM 2016 and Microsoft Dynamics CRM Online
Send comments about this topic to Microsoft.
© 2015 Microsoft. All rights reserved.