<EnableRule> (RibbonDiffXml)
Applies To: Dynamics CRM 2015
Specifies either the definition of a rule used to enable or disable a ribbon element or a reference to an EnableRule from a command definition.
Note
The EnableRule element child elements are only valid when it is a grandchild of <RuleDefinitions> (RibbonDiffXml).
Syntax
<CommandDefinition>
<EnableRules>
<EnableRule Id="String" />
</EnableRules>
</CommandDefinition>
<RuleDefinitions>
<EnableRules >
<EnableRule
Id="String">
<CommandClientTypeRule />
<CrmClientTypeRule />
<CrmOfflineAccessStateRule />
<CrmOutlookClientTypeRule />
<CustomRule />
<EntityRule />
<FormStateRule />
<OrRule />
<OutlookItemTrackingRule />
<OutlookVersionRule />
<PageRule />
<RecordPrivilegeRule />
<SelectionCountRule />
<SkuRule />
<ValueRule />
</EnableRule>
</EnableRules>
</RuleDefinitions>
Attributes and Elements
The following table lists the attributes, child elements, and parent elements.
Attributes
Attribute |
Description |
Type |
Usage |
---|---|---|---|
Id |
Either
|
String |
Required |
Child Elements
Element |
Description |
---|---|
Specifies a rule that detects the type of presentation being used. |
|
Specifies a rule that detects the type of Microsoft Dynamics CRM client. |
|
Specifies a rule that can be used to detect whether Microsoft Dynamics CRM for Outlook with Offline Access is currently operating offline. |
|
Specifies a rule that detects the type of Microsoft Dynamics CRM for Microsoft Office Outlook client. |
|
Specifies a rule used with an EnableRule definition that is composed of a reference to a function within a JavaScript library. |
|
Specifies a rule that can detect whether a specific entity is in context. |
|
Specifies a rule that can detect the state of the form. |
|
A rule that contains a collection of rules so that this rule will evaluate as true if any of the rules in the collection evaluates as true. |
|
A rule that detects whether the item is enabled for items tracked in Microsoft Dynamics CRM in order to enable a ribbon element. |
|
A rule that detects the version of Microsoft Office Outlook client. |
|
A rule that evaluates the address of the current page. |
|
A rule that detects a user’s privileges for a specific record in order to enable a ribbon element. |
|
A rule that detects how many items in a grid are selected. |
|
A rule that detects the Microsoft Dynamics CRM edition. |
|
A rule that detects the value of a specific field. |
Parent Elements
Element |
Description |
---|---|
Contains a collection of enable rules. |
Remarks
The <EnableRules> (RibbonDiffXml) element is used as a child of <RuleDefinitions> (RibbonDiffXml) and <CommandDefinition> (RibbonDiffXml). When the EnableRule element is a grandchild of RuleDefinitions it defines a rule and supports a variety of child rule elements. When EnableRule is a grandchild of CommandDefinition, it simply references the EnableRule definition using the Id attribute.
Element Information
XPath |
|
Schema Name |
|
Validation File |
RibbonTypes.xsd |
Can be Empty |
When a grandchild of <CommandDefinition> (RibbonDiffXml). |
See Also
Ribbon XML reference
Customize commands and the ribbon
© 2016 Microsoft. All rights reserved. Copyright