This is a migrated thread and some comments may be shown as answers.

Windows Explorer Demo

5 Answers 114 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
heavywoody
Top achievements
Rank 1
heavywoody asked on 26 Aug 2011, 03:25 AM
I have followed the Windows Explorer Treeview demo you have and everything works fine except that my Directory objects never have the expansion sign next to it, even though they all have sub folders and files.  I have tried troubleshooting many different things.  For example, in the Style Selector I made Directory use the Drive style because its expander works.  But it makes no difference.  The Style is definitely being used as I have tested it.  Does it have to do with it being on a Windows 7 box?  I ran the program as an Administrator as I was desperate and it had no effect.

5 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 29 Aug 2011, 09:59 AM
Hello Christian Loepp,

Can you please open a support ticket with a sample solution that demonstrates the issue? That way we will be able to investigate the issue in your scenario further and provide you with possible solutions.

Thank you in advance.

Kind regards,
Tina Stancheva
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

0
James DAmour
Top achievements
Rank 1
answered on 03 Feb 2012, 07:59 PM
Do you know if this was resolved?  I can't find an answer to this.

Also, it works fine under Win 2003 server, just not Win 7
0
Petar Mladenov
Telerik team
answered on 08 Feb 2012, 07:50 AM
Hi James Damour,

 This issue is still not resolved. You can track its progress in this PITS item. Currently, we cannot promise an estimated time frame when this will be resolved.

All the best,
Petar Mladenov
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Buzz
Top achievements
Rank 1
answered on 23 Mar 2012, 08:32 PM
I had this same problem.

I noticed when I removed the text color settings from the DirectoryItemStyle, the directories would take on the DriveItemStyle.  I'm no TreeView expert, so I assume it's normal for child tree items to inherit their style from their parent.
In any case, this gave me the idea that perhaps the DriveItemStyle's IsLoadOnDemandEnabled being bound to IsReady was somehow interfering with the DirectoryItemStyle's IsLoadOnDemandEnabled being set directly to True.

Taking a shot in the dark, I added a property to Directory called WorkAroundForceTrue and bound DirectoryItemStyle's IsLoadOnDemandEnabled property to that.  I set WorkAroundForceTrue to true in the Directory constructor.

It works!!

<Setter Property="IsLoadOnDemandEnabled" Value="{Binding WorkAroundForceTrue}"/>

public class Directory
{
    public Directory(string fullPath, string name)
    {
        this.FullPath = fullPath;
        this.Name = name;
        this.WorkAroundForceTrue = true;
        this.Childs = new ObservableCollection<object>();
    }
    public string FullPath
    {
        get;
        set;
    }
    public string Name
    {
        get;
        set;
    }
    public bool WorkAroundForceTrue
    {
        get;
        set;
    }
    public ObservableCollection<object> Childs
    {
        get;
        set;
    }
}
0
Hristo
Telerik team
answered on 27 Mar 2012, 02:18 PM
Hi,

RadTreeView has an issue related to IsLoadOnDemandEnabled when property is set in style without usage of data binding.
The workaround is simply to provide required value via binding (the binding has a greater priority than style setter).

Regards,
Hristo
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
TreeView
Asked by
heavywoody
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
James DAmour
Top achievements
Rank 1
Petar Mladenov
Telerik team
Buzz
Top achievements
Rank 1
Hristo
Telerik team
Share this question
or