Hide Context Menu

2 posts, 0 answers
  1. Developer
    Developer avatar
    35 posts
    Member since:
    Apr 2014

    Posted 17 Mar Link to this post

    I have a radtreeview that has a context menu.  I would like to hide the entire context menu based upon the value of the node attribute.
    I can kind of achieve this by hiding individual menu items, however a small animation is still shown even if no menu items are displayed.
    I would like to do this client side if possible.
  2. Dimitar
    Dimitar avatar
    277 posts

    Posted 18 Mar Link to this post


    You may enable/disable the context menu for a RadTreeView node client-side using the set_enableContextMenu() setter with true/false parameter. You may test it on the RadTreeView Context Menu demo. The following snippet would enable/disable the context menu for the 'Personal Folders' node:

    // Disable the menu
    // Enable the menu

    And on the server-side, you may use the respective EnableContextMenu property to enable/disable the menu for a given node.

    Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
  3. DevCraft R3 2016 release webinar banner
Back to Top