I have defined NodeLayout's as follows:
NodeLayout myLayout = new NodeLayout();myLayout.Key = "CompanyLayout";myLayout.TargetTypeName = "Company";myLayout.DisplayMemberPath = "company_name";
NodeLayout myLayout2 = new NodeLayout();myLayout2.Key = "SiteLayout";myLayout2.TargetTypeName = "SecurityApp.CAPs.Model.Site";myLayout2.DisplayMemberPath = "site_name";
MyTree.GlobalNodeLayouts.Add(myLayout);MyTree.GlobalNodeLayouts.Add(myLayout2);
But I'm only getting the top level Company name list in the tree display. Not seeing any expansion icons to the left of company name. I have checked everything I can think about. Compared to the example in the documentation, I can't see the differance. Any ideas on how to troubleshoot will be greatly appreciated.
Hi jgreen274,
I think the solution for your case is that you need to create those NodeLayouts and assign them to XamDataTree before setting its ItemSource. For example in the Loaded event of XamDataTree first create couple of NodeLayouts that adequate corespond to your objects and then set the ItemsSource to the XamDataTree. If you still have any difficulties please share them in order to assist you!
Regards,
Nikola
I am creating the NodeLayouts and assigning them to XamDataTree before setting its ItemsSource. Still have the problem. I have attached my Company.cs file because I'm wondering if the problem is due to the way my entities are defined. SiteCollection derives from ObservableCollection<Site> but for some reason Site is not being recognized as a target. Shouldn't this work?
I would have replied sooner but I've been trying every thing I can think of to no avail.
Thank you for your help,
Joe
That seems to solve the problem.
But, is this usage of the NodeLayout.Key property documented??
This is all it says in the API documentation for the Key Property:
Gets / sets the unique string which can be used to identify this NodeLayoutBase.
Thank you very much!!!
Hello Joe,
I have been looking into this and have found the link in the online documentation that you are looking for: http://help.infragistics.com/NetAdvantage/Silverlight/2011/1/CLR4.0/?page=xamDataTree_xamDataTree_Node_Layouts.html , also here is a quote from it:
“Key – This property defines the unique identifier of the node layout. If you want the tree to automatically create children nodes, this property can be set to the property of the objects in the initial collection. See the Local Layouts section for an example.”
When looking into the documentation, I can suggest going to the main link: http://help.infragistics.com/NetAdvantage/Silverlight/2011/1/CLR4.0/ , selecting “Developers Guide” tag, then “Control” so that you can get all the references for the control you are looking for.
Please let us know if you require any further assistance on them matter.
Hello Petar,
Thank you very much for the pointer to the documentation for 'Key'.
Unfortunately, I was using docs for version 10.3. The corresponding page (i.e. for xamDataTree Node Layouts) in the 10.3 documentation (local/offline ver.) only shows the first sentence in the description for 'Key'.
Can you give me compelling reasons to upgrade to 11.1 that I can use to sell my management?
Thanks again,
You can find a list of the new features in our WPF Line Of Business package at the following link:
http://help.infragistics.com/NetAdvantage/WPF/2011.1/CLR4.0/?page=WPF_Whats_New_in_2011_Volume_1.html
also please notice that we are constantly working on improving and ehancing our toolset. By the beginning of November we are aslo expecting to ship the new version-11.2 of our product, so I can suggest you aslo have a look also of a following article that disscuses some of the features that will be added:
http://blogs.infragistics.com/blogs/jason_beres/archive/2011/09/21/coming-this-fall-a-sneak-peek-at-11-2.aspx
If you have any furhter questions about this, please feel free to ask.
If you need any additional information about this or if you still have any questions or concerns on the matter, please do not hesitate to ask.