Treeview invisible

4 posts, 0 answers
  1. Matt
    Matt avatar
    5 posts
    Member since:
    May 2013

    Posted 17 May 2013 Link to this post

    I am evaluating the DevCraft suite for WPF, and I've run into an odd problem.  

    I'm developing an internal application for my company.  It uses .NET 4.5, WPF, Prism, and Entity Framework 5.0.

    When I instantiate a RadTreeView control and populate it with static RadTreeViewItem objects in the XAML, it doesn't display.  If I set the background color, I get a colored rectangle with no items.  Using Snoop I can see that it exists in the visual tree and the HasItems property is true.  This behavior is the same regardless of whether I navigate to a region using Prism or declare it manually in the shell window.

    If I create a separate application and place the static test RadTreeView in it, it behaves as expected.

    Any ideas?

  2. Pavel R. Pavlov
    Pavel R. Pavlov avatar
    1251 posts

    Posted 20 May 2013 Link to this post


    I already answered to your question in your support ticket. However I will post the same answer here so others from the community can find it.

    I can not be sure about your scenario and the reason behind this behavior. However, such behavior may occur if you use our NoXaml dlls. If you do, the controls used in your project will be created (added to the visual tree) but they will not be visualized because their visual representation (XAML code) is not available. You can read more information about the usage of our NoXaml dlls in this article. If you are not using the NoXaml dlls we will kindly ask you to provide us with more information (and snippets) about your scenario. How you load your modules and how are they structured? If we reproduce that behavior on our side we will be able to suggest the best approach in your case.

    I am looking forward to hearing from you.

    Pavel R. Pavlov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. Sreelaskshmi
    Sreelaskshmi avatar
    6 posts
    Member since:
    Aug 2014

    Posted 09 Jun 2017 Link to this post


    I am using "FallbackValue" in ItemSource binding for Treeview Control, till Data loaded completely.

    I am able to see FallbackValue till control loaded fully with data.But its coming vertically.I want to display it as Horizontally.

    Please refer attachment and suggest some solution.

    Sample code as below.

    <telerik:RadtreeView ItemSource ={Binding Data,FallBackValue=Loading..,IsAsync=True} />



  4. Martin Ivanov
    Martin Ivanov avatar
    2403 posts

    Posted 13 Jun 2017 Link to this post

    Hi Mohan,

    This behavior is expected. The ItemsSource expects a collection, so if you set it to a string value (a collection of char), the treeview will be populated with it. So, a node will be created for each char from the string. In your case you will have nodes for "L", "o", "a" and "d". 

    To achieve your requirement you will need to use a different approach. For example, you can hide the treeview while the data is loading and display a TextBlock saying that the treeview is loading. After the data is loaded, show the treeview and hide the TextBlock.

    Martin Ivanov
    Progress Telerik
    Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
Back to Top