<Label> (RibbonDiffXml)

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

指定一行用于提供信息的文本。

语法

<Label 
 Command="String"
 ForId="String"
 Id="String"
 Image16by16="String"
 Image16by16Class="String"
 Image16by16Left="Non Positive Integer"
 Image16by16Top="Non Positive Integer"
 LabelText="String"
 ModernImage=”String”
 QueryCommand="String"
 Sequence="Integer"
 TemplateAlias="String"
/>

属性和元素

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

属性

Attribute Description Type Usage

Command

指定此控件的功能区命令的 ID。

String

Optional

ForId

The ID of the control that this control labels.

String

Optional

Id

指定功能区元素的定义的唯一标识符。强烈推荐的命名约定是使用句点来分隔名称各部分的,如[solution identifier].[entity].[ribbon].[function].[element name]。例如: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

Image16by16

指定一个 16x16 像素的图像。这可以是某个图像文件的路径,也可以是使用 $webresource: 指令引用 Web 资源。

String

Optional

Image16by16Left

指定要将 16x16 像素的图像左移的像素数。此数字可由负数表示。

Non positive integer

Optional

Image16by16Top

指定要将 16x16 像素的图像上移的像素数。此数字可由负数表示。

Non positive integer

Optional

LabelText

指定要显示为控件的文本的字符串。这可以使用 $LocLabels: 指令引用 LocLabel 元素,例如“$LocLabels:MyISV.account.Save.Button.Label”。

String

Optional

ModernImage

仅供内部使用。

String

Optional

QueryCommand

指定在轮询状态信息时要运行的命令的名称。

String

Optional

Sequence

通过将序列值设置为高于或低于现有功能区元素来指定功能区修改内容的位置。

Integer

Optional

TemplateAlias

将 CommandUIDefinition 的功能区元素子级与 Layout 元素子级中的位置占位符关联。此值定义了控件在布局发生更改时在控件组中的显示位置。

String

Optional

子元素

此元素没有子元素。

父元素

Element Description

<CommandUIDefinition> (RibbonDiffXml)

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

元素信息

XPath

//RibbonDiffXml/CustomActions/CustomAction/CommandUIDefinition/Label

Schema Name

LabelType

Validation File

RibbonWSS.xsd

Can be Empty

Yes

另请参阅

其他资源

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

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