web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

SplitButton - Child Elements Aren't Clickable

(0) ShareShare
ReportReport
Posted on by

I have a SplitButton that I'm putting on a View (not an individual form) - the main Account one (Sales -> Accounts). i.e.,

Screen-Shot-2016_2D00_05_2D00_14-at-10.53.47-PM.png

I am using the Ribbon Workbench. I've created the button with an associated Command that links to a javaScript file on the back end.

When I click on the header ("Call Result") the javaScript fires. But the child elements are not clickable.

The header and child elements are set up the same way in the Ribbon Editor. I have configured the Command, all the ToolTip and other language elements, and the CommandCore, which contains the same thing as the Command.

Here's my XML. Note I've tried this with a flyout as well.

<RibbonDiffXml>
  <CustomActions>
    <CustomAction Id="myprefix.account.Button1.Button.CustomAction" Location="Mscrm.HomepageGrid.account.MainTab.Management.Controls._children" Sequence="29">
      <CommandUIDefinition>
        <SplitButton Alt="$LocLabels:myprefix.account.Button1.Button.Alt" Command="myprefix.account.RunWorkflowAMCallback" Id="myprefix.account.Button1.Button" LabelText="$LocLabels:myprefix.account.Button1.Button.LabelText" Sequence="29" TemplateAlias="o3" ToolTipTitle="$LocLabels:myprefix.account.Button1.Button.ToolTipTitle" ToolTipDescription="$LocLabels:myprefix.account.Button1.Button.ToolTipDescription">
          <Menu Id="myprefix.account.Button1.Button.Menu">
            <MenuSection Id="myprefix.account.Section2.Section" Title="$LocLabels:myprefix.account.Section2.Section.Title" Sequence="10" DisplayMode="Menu16">
              <Controls Id="myprefix.account.Section2.Section.Controls" />
            </MenuSection>
            <MenuSection Id="myprefix.account.Section3.Section.0" Title="$LocLabels:myprefix.account.Section3.Section.0.Title" Sequence="20" DisplayMode="Menu16">
              <Controls Id="myprefix.account.Section3.Section.Controls" />
            </MenuSection>
          </Menu>
        </SplitButton>
      </CommandUIDefinition>
    </CustomAction>
    <CustomAction Id="myprefix.account.FlyOut.Button.CustomAction" Location="Mscrm.HomepageGrid.account.MainTab.Management.Controls._children" Sequence="44">
      <CommandUIDefinition>
        <FlyoutAnchor Alt="$LocLabels:myprefix.account.FlyOut.Button.Alt" Command="myprefix.account.RunWorkflowAMCallback" Id="myprefix.account.FlyOut.Button" LabelText="$LocLabels:myprefix.account.FlyOut.Button.LabelText" Sequence="44" TemplateAlias="o3" ToolTipTitle="$LocLabels:myprefix.account.FlyOut.Button.ToolTipTitle" ToolTipDescription="$LocLabels:myprefix.account.FlyOut.Button.ToolTipDescription">
          <Menu Id="myprefix.account.Button2.Button.Menu">
            <MenuSection Id="myprefix.account.Section3.Section" Title="$LocLabels:myprefix.account.Section3.Section.Title" Sequence="10" DisplayMode="Menu16">
              <Controls Id="myprefix.account.Section3.Section.Controls" />
            </MenuSection>
          </Menu>
        </FlyoutAnchor>
      </CommandUIDefinition>
    </CustomAction>
  </CustomActions>
  <Templates>
    <RibbonTemplates Id="Mscrm.Templates"></RibbonTemplates>
  </Templates>
  <CommandDefinitions>
    <CommandDefinition Id="myprefix.account.RunWorkflowAMCallback">
      <EnableRules>
        <EnableRule Id="Mscrm.SelectionCountAtLeastOne" />
      </EnableRules>
      <DisplayRules />
      <Actions>
        <JavaScriptFunction FunctionName="invokeWorkflowAMCallback" Library="$webresource:yp_fireWorkflow">
          <CrmParameter Value="FirstSelectedItemId" />
        </JavaScriptFunction>
      </Actions>
    </CommandDefinition>
  </CommandDefinitions>
  <RuleDefinitions>
    <TabDisplayRules />
    <DisplayRules />
    <EnableRules />
  </RuleDefinitions>
  <LocLabels>
    <LocLabel Id="myprefix.account.Button1.Button.Alt">
      <Titles>
        <Title description="Resolve This Call" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.Button1.Button.LabelText">
      <Titles>
        <Title description="Call Result" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.Button1.Button.ToolTipDescription">
      <Titles>
        <Title description="Resolve This Call" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.Button1.Button.ToolTipTitle">
      <Titles>
        <Title description="Resolve This Call" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.FlyOut.Button.Alt">
      <Titles>
        <Title description="FlyOut" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.FlyOut.Button.LabelText">
      <Titles>
        <Title description="FlyOut" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.FlyOut.Button.ToolTipDescription">
      <Titles>
        <Title description="FlyOut" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.FlyOut.Button.ToolTipTitle">
      <Titles>
        <Title description="FlyOut" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.Section2.Section.Title">
      <Titles>
        <Title description="Callback - AM" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.Section3.Section.0.Title">
      <Titles>
        <Title description="Callback - PM" languagecode="1033" />
      </Titles>
    </LocLabel>
    <LocLabel Id="myprefix.account.Section3.Section.Title">
      <Titles>
        <Title description="AM Callback" languagecode="1033" />
      </Titles>
    </LocLabel>
  </LocLabels>
</RibbonDiffXml>


*This post is locked for comments

I have the same question (0)
  • Suggested answer
    ScottDurow Profile Picture
    21 on at

    Hi,

    Rather than use menu sections you need to add buttons to  the section and add a  command to each button.

    Hope this helps

  • ScottDurow Profile Picture
    21 on at

    How did you get on?

  • Bob Hatcher Profile Picture
    on at

    Hi ScottDurow, thanks for following up. I did get it to work.

    For the benefit of anyone who finds this later on, this is what the config looks like:

    Screen-Shot-2016_2D00_05_2D00_17-at-9.07.43-PM.png

    which results in this:

    Screen-Shot-2016_2D00_05_2D00_17-at-9.07.43-PM.png

    Where the word "Menu" is clickable and fires the JavaScript Command. Another thing to keep in mind that I found from another comment of Scott's is that the Web Resource containing the JavaScript needs to be part of the Solution you import into the Ribbon Editor.

    In the Enable Rule, set IsCore = True.

    Thanks again!

  • HenriquePalomo Profile Picture
    510 on at

    Hello Bob.

    Sorry, i did not understand how could you fix that.

    I'm stuck in the same problem. I have added flyout buttons, and inside the flyout buttons i have added a menu section and workflow button. Take a look at the picture below.

    Flyout.PNG

  • HenriquePalomo Profile Picture
    510 on at

    Hello all.

    I did many tests here and the problem above just happen if i put more than 3 Flyout/Split buttons together. 
    Probably it is a bug.

    Regards.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans