1

I m trying to add checkbox in ribbon control but i m not able to do so. I have tried to use barEdtitItem but it is not working. I m using devexpress riboon control and i didn't got its solution online. Please find the attached image.enter image description here

abc
  • 75
  • 11

2 Answers2

1

You can use bar items in ribbon inside quick access toolbar (RibbonControl.ToolbarItemLinks property), page header (RibbonControl.PageHeaderItemLinks property) or inside page groups. Thus you should define a category, page and group to show bar item inside the ribbon. Note that you cannot put bar items into the page group directly so you should define it inside the BarManager.Items collection first.

<dxb:BarManager>
    <dxb:BarManager.Items>
        <dxb:BarEditItem x:Name="bEdit" EditValue="true" EditSettings="{dxe:CheckSettings}"/>
    </dxb:BarManager.Items>
    <dxr:RibbonControl>
        <dxr:RibbonDefaultPageCategory>
            <dxr:RibbonPage Caption="Home">
                <dxr:RibbonPageGroup Caption="First">
                    <dxb:BarItemLink BarItemName="bEdit"/>
                </dxr:RibbonPageGroup>
            </dxr:RibbonPage>
        </dxr:RibbonDefaultPageCategory>
    </dxr:RibbonControl>
</dxb:BarManager>
Alexis
  • 815
  • 6
  • 15
0

You have to create an RibbonPageCatogory first. Inside that element you can define the BarEditItem.

<dxb:RibbonPageCategory x:Name="category">
// Your elements here
</dxb:RibbonPageCategory>
Jevgeni Geurtsen
  • 3,133
  • 4
  • 17
  • 35
  • I have tried what u said but it is still not working and giving the same error. – abc May 22 '14 at 07:04
  • I got the checkbox in ribbon using pagegroup but can u tell if i can use checkbox in ribbon page without using pagegroup. – abc May 22 '14 at 07:49
  • 1
    I'm not sure, but you can try it with and without and see which solution works. Although I think a PageGroup is needed.. – Jevgeni Geurtsen May 22 '14 at 08:04