TreeView ContextMenu when tree empty

4 posts, 0 answers
  1. Alan Sauls
    Alan Sauls avatar
    12 posts
    Member since:
    Dec 2009

    Posted 23 Feb 2010 Link to this post

    How do I suppress the displaying of the contextmenu when a treeview is empty?
  2. Tina Stancheva
    Admin
    Tina Stancheva avatar
    3299 posts

    Posted 01 Mar 2010 Link to this post

    Hi Alan Sauls,

    Can you please elaborate on the issue. Do you want to hide a custom context menu that you have created or you want to disable the default Silverlight context menu?

    If you can send us a small sample application which illustrates your problem exactly we will be able to debug it locally and provide you with a solution.

    Regards,
    Tina Stancheva
    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.
  3. Alan Sauls
    Alan Sauls avatar
    12 posts
    Member since:
    Dec 2009

    Posted 01 Mar 2010 Link to this post

    Since I was connecting the contextmenu to a hierarchicaldatatemplate I needed to use  the solution here:  http://www.telerik.com/help/wpf/radtreeview-how-to-add-context-menu.html

  4. Kiril Stanoev
    Admin
    Kiril Stanoev avatar
    1512 posts

    Posted 02 Mar 2010 Link to this post

    Hello Alan,

    We are still not sure that we understand what exactly the problem is. The link you have posted in your previous post (http://www.telerik.com/help/wpf/radtreeview-how-to-add-context-menu.html) was for WPF whereas your forum thread is for Silverlight. Which exactly is your target platform since there are differences between using context menu in Silverlight and WPF?
    Additionally, if you are targeting WPF and you have added context menu to your HierarchicalDataTemplate, there should be no reason to see a context menu appearing if the treeview is empty. Please take a look at the attached sample project.
    Let us know how we can be of further reference.

    Kind regards,
    Kiril Stanoev
    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