1

リードリボンにカスタムボタンがあります。リードが評価されると、カスタム ボタンを非表示にする必要があります。どうやってやるの?誰でも説明してください。感謝します。

4

1 に答える 1

2

実際には、組み込み機能を使用してこれを完全に実現できDisplayRuleます。aLeadが修飾されている場合、プロパティは「修飾済み」に設定され、値「3」にStatusCode変換されます。OptionSetでこのプロパティの値を確認しValueRule、コントロールを適切に表示/非表示にすることができます。これを実現するには、次の 2 つの方法が考えられます。

Erik Pool のビジュアル リボン エディター 鉛

リボンXml

<RibbonDiffXml>
  <CustomActions>
    <CustomAction Id="CompanyName.Form.lead.MainTab.Actions.Sample.CustomAction" Location="Mscrm.Form.lead.MainTab.Actions.Controls._children" Sequence="41">
      <CommandUIDefinition>
        <Button Id="CompanyName.Form.lead.MainTab.Actions.Sample" Command="CompanyName.Form.lead.MainTab.Actions.Sample.Command" Sequence="29" ToolTipTitle="$LocLabels:CompanyName.Form.lead.MainTab.Actions.Sample.LabelText" LabelText="$LocLabels:CompanyName.Form.lead.MainTab.Actions.Sample.LabelText" ToolTipDescription="$LocLabels:CompanyName.Form.lead.MainTab.Actions.Sample.Description" TemplateAlias="isv" />
      </CommandUIDefinition>
    </CustomAction>
  </CustomActions>
  <Templates>
    <RibbonTemplates Id="Mscrm.Templates"></RibbonTemplates>
  </Templates>
  <CommandDefinitions>
    <CommandDefinition Id="CompanyName.Form.lead.MainTab.Actions.Sample.Command">
      <EnableRules />
      <DisplayRules>
        <DisplayRule Id="CompanyName.Form.lead.MainTab.Actions.Sample.Command.DisplayRule.ValueRule" />
      </DisplayRules>
      <Actions>
        <Url Address="http://www.bing.com" />
      </Actions>
    </CommandDefinition>
  </CommandDefinitions>
  <RuleDefinitions>
    <TabDisplayRules />
    <DisplayRules>
      <DisplayRule Id="CompanyName.Form.lead.MainTab.Actions.Sample.Command.DisplayRule.ValueRule">
        <ValueRule Field="statuscode" Value="3" />
      </DisplayRule>
    </DisplayRules>
    <EnableRules />
  </RuleDefinitions>
  <LocLabels>
    <LocLabel Id="CompanyName.Form.lead.MainTab.Actions.Sample.LabelText">
      <Titles>
        <Title languagecode="1033" description="Sample" />
      </Titles>
    </LocLabel>
    <LocLabel Id="CompanyName.Form.lead.MainTab.Actions.Sample.Description">
      <Titles>
        <Title languagecode="1033" description="Sample Description" />
      </Titles>
    </LocLabel>
  </LocLabels>
</RibbonDiffXml>
于 2012-07-25T15:28:33.277 に答える