This is a migrated thread and some comments may be shown as answers.

StaysOpenOnClick property not working

3 Answers 127 Views
RibbonView and RibbonWindow
This is a migrated thread and some comments may be shown as answers.
Richard Harrigan
Top achievements
Rank 1
Richard Harrigan asked on 22 Mar 2013, 07:16 PM
Hi

I am using a RadMenu as content for RadRibbonDropDownButton.  I want the user to be able to select multiple RadMenuItems so I set StaysOpenOnClick=true but the menu doesn't stay open.  I also tried it as a sub menu with the same result.  See xaml below.

Thanks
Rich


                        <telerik:RadRibbonDropDownButton CollapseToMedium="WhenGroupIsMedium"
                                SmallImage="/Icons/16/find.png"                                                  
LargeImage="/Icons/32/twitter.png" Size="Large" Text="Panes">
                            <telerik:RadRibbonDropDownButton.DropDownContent>
                                <telerik:RadMenu Name="panes" Orientation="Vertical"> 
                                    <telerik:RadMenuItem Header="Navigation"
                                       Uid="1"
                                       IsCheckable="True"
                                       IsChecked="True" 
                                       Checked="RadMenuItem_Checked"
                                       Unchecked="RadMenuItem_Unchecked"
                                       StaysOpenOnClick="True" />
                                    <telerik:RadMenuItem Header="Available Tables"
                                       Uid="2"
                                       IsCheckable="True"
                                       IsChecked="True"
                                       Checked="RadMenuItem_Checked"
                                       Unchecked="RadMenuItem_Unchecked"
                                       StaysOpenOnClick="True" />
                                    <telerik:RadMenuItem IsSeparator="True" />
                                    <telerik:RadMenuItem Header="Criteria Columns"
                                       Uid="3"
                                       IsCheckable="True"
                                       IsChecked="True"
                                       Checked="RadMenuItem_Checked"
                                       Unchecked="RadMenuItem_Unchecked"
                                       StaysOpenOnClick="True" />                                 
                                    <telerik:RadMenuItem Header="Sql Statement"
                                       Uid="4"
                                       IsCheckable="True"
                                       IsChecked="True" 
                                       Checked="RadMenuItem_Checked"
                                       Unchecked="RadMenuItem_Unchecked"
                                       StaysOpenOnClick="True" />
                                    <telerik:RadMenuItem Header="Data Sheet"
                                       Uid="5"
                                       IsCheckable="True"
                                       IsChecked="True" 
                                       Checked="RadMenuItem_Checked"
                                       Unchecked="RadMenuItem_Unchecked"
                                       StaysOpenOnClick="True" />
                                    <telerik:RadMenuItem Header="Data Filter and Expression"
                                       Uid="6"
                                       IsCheckable="True"
                                       IsChecked="True"
                                       Checked="RadMenuItem_Checked"
                                       Unchecked="RadMenuItem_Unchecked"
                                       StaysOpenOnClick="True" />
                                </telerik:RadMenu>
                            </telerik:RadRibbonDropDownButton.DropDownContent>
                        </telerik:RadRibbonDropDownButton>

3 Answers, 1 is accepted

Sort by
0
Pavel R. Pavlov
Telerik team
answered on 27 Mar 2013, 03:38 PM
Hello Richard,

In order to select multiple RadMenuItems you can set the KeepOpen property of the RadRibbonDropDownButton to True.

Have in mind that by setting the KeepOpen property you will heave to click on the button (again) to close the drop down content. Closing the drop down content by clicking outside it is not supported. If you need to implement similar behavior you can try handling the Click event in the MainWindow and check the position of the mouse pointer. If the pointer is outside the drop down content you can manually close it by setting the RadRibbonDropDownButton.IsOpen property to False.

We will be happy to further assist you on implementing such a behavior.

Regards,
Pavel R. Pavlov
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Aurore
Top achievements
Rank 1
answered on 04 Apr 2013, 07:40 AM
Hello,
I need to resolve the same issue.
Can you give us a sample ?

Thanks
Aurore
0
Pavel R. Pavlov
Telerik team
answered on 08 Apr 2013, 02:07 PM
Hello Aurore,

Please find attached the described approach.

Regards,
Pavel R. Pavlov
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
RibbonView and RibbonWindow
Asked by
Richard Harrigan
Top achievements
Rank 1
Answers by
Pavel R. Pavlov
Telerik team
Aurore
Top achievements
Rank 1
Share this question
or