RibbonBar StartMenu problem

13 posts, 0 answers
  1. GUIjunkie
    GUIjunkie avatar
    10 posts
    Member since:
    May 2007

    Posted 04 Jun 2007 Link to this post

    I've added a StartMenu with menu items to a RibbonBar.

    The problem is that I see an Options and Exit button in my menu and would like to NOT have them there.  I can't find where to remove these two button items.

    Thanks...
  2. GUIjunkie
    GUIjunkie avatar
    10 posts
    Member since:
    May 2007

    Posted 04 Jun 2007 Link to this post

    ok, i've removed the Options and Exit buttons from the main menu; however, i still show a right column with nothing in it and the property relating to the right column menu is set to false. 
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Jack
    Admin
    Jack avatar
    2335 posts

    Posted 05 Jun 2007 Link to this post

    Hello John,

    You can access the StartMenu in RadRibbonBar and hide the right column by using this code:

    RadDropDownButtonElement button = (RadDropDownButtonElement)this.radRibbonBar1.RibbonBarElement.Children[2];
    RadSubMenuLayoutPanel panel = (RadSubMenuLayoutPanel)button.DropDownMenu.PopupElement;
    panel.IsTwoColumnMenu = false;


    Let us know if this helps.
     

    Greetings,
    Jack
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  5. GUIjunkie
    GUIjunkie avatar
    10 posts
    Member since:
    May 2007

    Posted 05 Jun 2007 Link to this post

    yes, this did work; however, why can't this be done during design as oppossed to runtime?

    thanks...
  6. Jack
    Admin
    Jack avatar
    2335 posts

    Posted 06 Jun 2007 Link to this post

    Good point, John, this is an issue and we will fix it in our next major release (Q2 2007). Thanks for the feedback.

    Greetings,
    Jack
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  7. Anders Bergström
    Anders Bergström avatar
    2 posts
    Member since:
    Mar 2010

    Posted 15 Apr 2010 Link to this post

    Hi,
    Is the issue with hiding the right column now really included in design time? I'm using Q1 2010 SP1, and I can't find this feature anywhere in design time. I also have trouble compiling the code example for hiding the right column programatically since I can't find the assembly to reference that includes the RadSubMenuLayoutPanel? Am I missing something here...?

    Could you also show how to solve GUIjunkies initial question on how to hide the Options and Exit buttons? I have the same problem.

    Thanks.
  8. Deyan
    Admin
    Deyan avatar
    2039 posts

    Posted 21 Apr 2010 Link to this post

    Hi Anders,

    Thanks for writing and for your questions.

    You can hide the Options- and ExitButton by accessing them from the property grid of the RadRibbonBar while in the Visual Studio Designer. There are two properties which expose both buttons. You can expand their sub-properties and find the Visibility property and set it according to your preferences.

    You can also hide these buttons programmatically the following way:
     

    this.radRibbonBar1.OptionsButton.Visibility = Telerik.WinControls.ElementVisibility.Collapsed;
    this.radRibbonBar1.ExitButton.Visibility = Telerik.WinControls.ElementVisibility.Collapsed;

    Hiding the right column in the Application Menu is possible only programmatically. The following code snippet demonstrates how to achieve this:

    this.radRibbonBar1.RibbonBarElement.ApplicationMenuRightColumnWidth = 0;

    I hope this is helpful.

    Do not hesitate to write back anytime you have further questions or need assistance.

    All the best,
    Deyan
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  9. Nabeel
    Nabeel avatar
    3 posts
    Member since:
    Nov 2010

    Posted 25 Nov 2010 Link to this post

    I tried all ways using

                this.radRibbonBar1.RibbonBarElement.ApplicationMenuRightColumnWidth=0;

    but it shows error  this.radRibbonBar1.RibbonBarElement.ApplicationMenuRightColumnWidth as Read only. which is unassignable...
  10. Nikolay
    Admin
    Nikolay avatar
    1803 posts

    Posted 25 Nov 2010 Link to this post

    Hello Nabeel,

    In order to hide the right part of the RadRibbonBar main menu, you should set the ShowTwoColumnDropDownMenu property to false:
    this.radRibbonBar1.RibbonBarElement.ApplicationButtonElement.ShowTwoColumnDropDownMenu = false;


    Kind regards,
    Nikolay
    the Telerik team
    Get started with RadControls for WinForms with numerous videos and detailed documentation.
  11. Nabeel
    Nabeel avatar
    3 posts
    Member since:
    Nov 2010

    Posted 27 Nov 2010 Link to this post

    this.radRibbonBar1.RibbonBarElement.ApplicationButtonElement.ShowTwoColumnDropDownMenu = false;


    I tried this code, mention above.
    "this.radRibbonBar1.RibbonBarElement.ApplicationButtonElement" is successfully detected by Visual Studio 2008 but the method "ShowTwoColumnDropDownMenu" doesn't appear and it shows Message on mouse over:

    'Telerik.WinControls.UI.RadDropDownButtonElement' doesn't contain a defination for 'ShowTwoColumnDropDownMenu' and no extension method 'ShowTwoColumnDropDownMenu' accepting a first arguement of type 'Telerik.WinControls.UI.RadDropDownButtonElement' could be found (are you missing a using directive or an assembly reference?)
  12. Nikolay
    Admin
    Nikolay avatar
    1803 posts

    Posted 02 Dec 2010 Link to this post

    Hello Nabeel,

    Most probably, you are experiencing the issue, because you are using an old version of our controls where the property does not exist. Please update to our latest version Q3 2010 and try again.

    Let me know if you still experience any issues with this.

    Best wishes,
    Nikolay
    the Telerik team
    Get started with RadControls for WinForms with numerous videos and detailed documentation.
  13. Dadan
    Dadan avatar
    6 posts
    Member since:
    Nov 2012

    Posted 01 Apr 2013 Link to this post

    Hi GUIjunkie,,

     can you tell me how to remove The Option and Exit button from the start menu ??
  14. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 04 Apr 2013 Link to this post

    Hi Dadan,

    There are properties of the control allowing you to access these buttons, and from there you can set their Visibility:
    radRibbonBar1.OptionsButton.Visibility = ElementVisibility.Collapsed;
    radRibbonBar1.ExitButton.Visibility = ElementVisibility.Collapsed;

    I hope this helps.

    Kind regards,
    Stefan
    the Telerik team
    WinForms Q1 2013 boasts PivotGrid, PDF Viewer, Chart enhancements and more. Check out all of the latest highlights.
Back to Top
UI for WinForms is Visual Studio 2017 Ready