ShowArrow works in designer but not at runtime

11 posts, 0 answers
  1. Adam
    Adam avatar
    89 posts
    Member since:
    Mar 2008

    Posted 01 Oct 2008 Link to this post

    I can't seem to get RadMenuItems to be drawn with the arrow next to them when they are top level menus.  They show in the designer when I change the item's ShowArrow property to true.

    I also want to be able to Edit UI Items and change the arrow direction to down and change the arrow's color.  After I get done in the designer, it looks great, but when I run I get no arrows, and sometimes when rebuilding the project, the arrow direction does not stay on my selection at design-time.
  2. Jack
    Admin
    Jack avatar
    2333 posts

    Posted 01 Oct 2008 Link to this post

    Hi Adam,

    Thank you for contacting us.

    You should set explicitly the ShowArrow property to true in order to make the arrow visible in the main menu. Additionally you can change the arrow direction by accessing the ArrowPrimitive through the Layout property of RadMenuItem.

    Take a look at the code snippet below:

    this.radMenuItem1.ShowArrow = true
    this.radMenuItem1.Layout.ArrowPrimitive.Direction = Telerik.WinControls.ArrowDirection.Down; 
     


    Use the following code to change the arrow color :

    this.radMenuItem1.Layout.ArrowPrimitive.ForeColor = Color.Yellow; 


    I hope this helps. Do not hesitate to contact me if you need further assistance.

    Sincerely yours,
    Jack
    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. Adam
    Adam avatar
    89 posts
    Member since:
    Mar 2008

    Posted 01 Oct 2008 Link to this post

    Sorry, I am not seeing the behavior of explicitly setting RadMenuItem.ShowArrow = true causing the arrows to show.  I have not been able to get the arrow to show up at all. 

    Steps I took for the simplest case:

    1. Create new VS 2008 Windows Forms Application Project
    2. Drag and Drop a RadMenu onto Form1
    3. Add a RadMenuItem to the menu by typing in the "Type here" box
    4. Select the RadMenuItem I just created
    5. Changed the property "ShowArrow" to True
    6. See arrows in the designer
    7. Run Project, no arrows on the menu item
    8. In the Form1 constructor, add the line radMenuItem1.ShowArrow = true;
    9. Run Project, no arrows on the menu item
  5. Jack
    Admin
    Jack avatar
    2333 posts

    Posted 02 Oct 2008 Link to this post

    Hi Adam,

    You should set the ShowArrow property through code after calling the InitializeComponent in Form's constructor or inside the Form.Load event. You should also reset the ShowArrow property to its default value at design time. We have logged this issue and it will be addressed in one of our upcoming releases.

    Should you have any questions, don't hesitate to ask.

    Kind regards,
    Jack
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  6. Adam
    Adam avatar
    89 posts
    Member since:
    Mar 2008

    Posted 02 Oct 2008 Link to this post

    Setting ShowArrow = false in the designer is the trick that finally did it.  Thank you for your help.
  7. Jorge Delgado-Lopez
    Jorge Delgado-Lopez avatar
    82 posts
    Member since:
    Aug 2007

    Posted 08 Mar 2010 Link to this post

    Hi.

    I have a problem setting the ShowArrow property to false on menu items that I add at runtime. The menu system exists in a UserControl which I have added to a RadForm at design time.

    Any ideas?
    - jorge
  8. Deyan
    Admin
    Deyan avatar
    2041 posts

    Posted 11 Mar 2010 Link to this post

    Hello Jorge Delgado-Lopez,

    Thanks for writing. I am not quite sure that I correctly understand the case you are describing. Could you please give us more details on what you are trying to achieve or possibly a small Windows Forms application that we can use to reproduce the case. This will help us provide better support. Please note that you will have to open a new support ticket in order to be able to attach your project. I look forward to receiving the requested details. Do not hesitate to write back anytime you need further assistance.

    Best wishes,
    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. Jorge Delgado-Lopez
    Jorge Delgado-Lopez avatar
    82 posts
    Member since:
    Aug 2007

    Posted 11 Mar 2010 Link to this post

    Hi

    I uploaded a project showing the problem, or my lack of knowledge about telerik's component creation lifecycle.

    http://www.zshare.net/download/735806420676a233/

    Thanks
    / jorge
  10. Deyan
    Admin
    Deyan avatar
    2041 posts

    Posted 12 Mar 2010 Link to this post

    Hi Jorge Delgado-Lopez,

    Thanks for writing back and for your project. I took a look at it but I am not quite sure that I correctly understand the case. You are setting the ShowArrow property to false and no arrow is displayed when I run the project. I think this is the expected behavior. Could you please share with us which version of our product are you using and what is the behavior that you expect?

    Thanks for your time and do not hesitate to get back to us in case you have further questions or need assistance.

    Regards,
    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.
  11. Jorge Delgado-Lopez
    Jorge Delgado-Lopez avatar
    82 posts
    Member since:
    Aug 2007

    Posted 12 Mar 2010 Link to this post

    Hi!

    I am on Telerik 2009.3.9.1111 and I do see the arrow, and I excpect NO arrow. I will try it witlh the 2010 release you just made. Downloading now....

    / jorge

  12. Nikolay
    Admin
    Nikolay avatar
    1804 posts

    Posted 18 Mar 2010 Link to this post

    Hello Jorge Delgado-Lopez,

    You should have no issues with hiding the arrow from the main menu items using the ShowArrow property. Let me know if you have further questions on this topic.

    All the best,
    Nikolay
    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.
Back to Top
UI for WinForms is Visual Studio 2017 Ready