RadMenu Problem

7 posts, 0 answers
  1. Hassan
    Hassan avatar
    15 posts
    Member since:
    Jan 2009

    Posted 16 Jan 2009 Link to this post

    Hi,

    I added RadMenuitems as sub items of a RadDropDownButton, I set the autosize property of the RadMenuItems to false and set the size of RadMenuItems and whole DropDownMenu (of Parent DropDownButton) manually. 

    Problem: All works fine but the problem is with the SubMenu of RadMenuItem, when the PopUpDirection is on the left side its right boundary does not meet with the left side of the parent menu i.e. leave some space in between. 

    My need is to change size of the RadMenuItems, is there any other proper way to do this? and is there a way to eliminate this space?

    Thanks

    Hassan   
  2. Deyan
    Admin
    Deyan avatar
    2037 posts

    Posted 19 Jan 2009 Link to this post

    Hi Hassan,

    Thanks for your interest in RadControls for WinForms.

    I have tried to reproduce the described behavior unsuccessfully so could you please send me a sample project that demonstrates the issue so that I can further investigate it. In general, I would not recommend that you manually set the size of the dropdown menu and its subitems, because in this way the layout system which arranges the visual elements may not function properly.

    Please note that you have to open a new support ticket so that you can attach files. Do not hesitate to write back if you have further questions, some feedback, or suggestions.

    Best wishes,
    Deyan
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Anoop
    Anoop avatar
    3 posts
    Member since:
    Oct 2013

    Posted 24 Oct 2013 Link to this post

         I am also facing the same problem. When there  is no space on the right side for the sub menu to open, it will open on the left side.
    In that case its right boundary does not meet with the left side of the parent menu. There is some vertical space between sub menu and parent menu. Please find one solution.

    Thanks
    Anoop K
  5. Anoop
    Anoop avatar
    3 posts
    Member since:
    Oct 2013

    Posted 24 Oct 2013 Link to this post

         I am also facing the same problem. When there  is no space on the right side for the sub menu to open, it will open on the left side.
    In that case its right boundary does not meet with the left side of the parent menu. There is some vertical space between sub menu and parent menu. Please find one solution.

    Thanks
    Anoop K
  6. Dess
    Admin
    Dess avatar
    1601 posts

    Posted 28 Oct 2013 Link to this post

    Hello Anoop,

    Thank you for contacting Telerik Support.

    I have tried to reproduce the described problem without any success. Here is my sample code achieving the result from the attached picture:
    public Form1()
    {
        InitializeComponent();
     
        RadMenuItem item1 = new RadMenuItem("item1");        
        item1.AutoSize = false;
        item1.Size = new Size(100, 20);
     
        RadMenuItem subitem1 = new RadMenuItem("sub-item1");
        subitem1.AutoSize = false;
        subitem1.Size = new System.Drawing.Size(50, 20);
        item1.Items.Add(subitem1);
     
        RadMenuItem subitem2 = new RadMenuItem("sub-item2");
        subitem2.AutoSize = false;
        subitem2.Size = new System.Drawing.Size(50, 20);
        item1.Items.Add(subitem2);
     
        item1.PopupDirection = RadDirection.Left;
        this.radDropDownButton1.Items.Add(item1);
     
        this.radDropDownButton1.DropDownDirection = RadDirection.Right;
        this.radDropDownButton1.DropDownButtonElement.DropDownMenu.AutoSize = false;
        this.radDropDownButton1.DropDownButtonElement.DropDownMenu.MinimumSize = new Size(100, 50);
    }

    Could you please share your sample code which reproduces this undesired behavior? Thank you in advance.

    I am looking forward to your reply.

    Regards,
    Desislava
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINFORMS.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  7. Anoop
    Anoop avatar
    3 posts
    Member since:
    Oct 2013

    Posted 28 Oct 2013 Link to this post

        I had the problem faced in web, not in windows application. The pop up direction is not set as left, which is right itself. It ll come left only when there is no space in the right side. You can check with the rad menu example in your demo.
    https://demos.telerik.com/aspnet-ajax/menu/examples/overview/defaultcs.aspx

        I had attached the screen shot. This is the same thing happened in my case also.
  8. Kate
    Admin
    Kate avatar
    1898 posts

    Posted 30 Oct 2013 Link to this post

    Hello Anoop ,

    In case your issue is related to the web controls I would suggest that you post your issue in the ASP.NET AJAX forums instead of the forums related to t he windows controls. Thus we could be able to avoid any confusion that might occur in our communication.

    I will also post the answer of your question here for your reference. However, I would ask you to continue the communication in the ticket with id 751315 to avoid any further misunderstandings.

    Considering the issue that you describe I can suggest that you try using the following css class selectors in order to workaround the issue that you experience:
    div.RadMenu .rmRoundedCorners ul.rmGroup .rmSlide,
     ul.rmRoundedCorners ul.rmGroup .rmSlide
    {
    /*by changing the value you can adjust to get the needed look*/
    margin-left: -1px;
      }

    Regards,
    Kate
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Back to Top
UI for WinForms is Visual Studio 2017 Ready