If( = 0 || (tier3Object1 => tier3Object1. NOTE: By doing this, I don't kow if the property can be SET, but it can certainly be used to get the selected item. (tier2Object = new Tier2Object(currentFamilyName)) I would approach this by creating a control that inherits TreeView, and has the SelectedItem property with a dependency property so it can be used in XAML code and bindings. If( = 0 || (tier2Object1 => tier2Object1.Tier2FamilyName != currentFamilyName)) Var currentFamilyName = revitElementInstance.FamilyName I still think that WPF is an awesome platform There are, however, a couple. Tier1CategoryNames.Add(tier1Object = new Tier1Object(currentCategoryName)) Search: Kendo Grid Popup Editor Template Mvc. If(Tier1CategoryNames.Count = 0 || Tier1CategoryNames.All(tier1Object1 => tier1Object1.Tier1CategoryName != currentCategoryName)) Tier1CategoryNames = new ObservableCollection() įoreach(var revitElementInstance in _revitElementInstances) Private static void InitializeDataSource() Way shorter and simpler than i thought it would be. The method below is truly the meat of the solution and along with the XAML in the previously attached ZIP file make it work. Initially, my inexperience drove me to go the "safe" route towards populating the TreeView but on thursday i deleted most of what id done and fully embraced MVVM and working with Objects, in an object, in an object, in an object! Was a mind melter for me but it really paid off! I will gladly share this solution with any needing it so if you're interested please contact me. Much has happened since last Wednesday and i can report back that i now have a virtualized TreeView which will quickly handles projects with 200,000+ model elements! Jeremy, thank you for your suggestions and for continuing to help me and the community! Ive attached a zip file with the code in question.Ive enabled UI Virtualization to show more as a user expands each node.The TreeView is initially fully collapsed with only the first tier showing.There are 4 tiers (See screenshot 1) of data arranged in the following manner.Ive submitted a support ticket to Telerik which only confirmed that the code should be working and does outside of Revit where I can create 180000 objects into 4 tiers in seconds.Ive timed the Filtered Element Collectors and found they are incredible fast and dont seem to be the issue.I'm using WPF / XAML / MVVM / C# to build it.Here is some additional pertinent information. Project with less than 400 model Element Instances it takes about 5 seconds to build.Project with around 66,000 model Element Instances it takes about a minute to build.Project with around 150,000 model Element Instances it takes about 2 minutes to build. A new set of properties namely SelectedTreeItem have been defined to bind SelectedItem value for TreeViewAdv in MVVM pattern.Some examples of window load times below. I'm not sure what to suspect now and am hoping one of the community has ran across this. The problem is that even with UI Virtualization the window load times are far too long. A tool i'm building has a TreeView Control (Telerik RadTreeView) which will show all element instances in a Project/Active/Selection.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |