XML and Telerik RadTreeview - HierarchicalDataTemplate

Yellin

New Member
I'm working on a project for a client, where the app I'm building will serve to edit an XML file consumed by a live application. The application is written in Flash, and quite unstable, so I am kind of stuck with the less than optimal XML setup.The XML is made up (simplified) like the following:\[code\]<MenuItem id="1" label="category1"> <Description>Description for Category 1</Description> <Image>Image for category 1</Image> <Item label ="Category1Item1"> <Price>12.99</Price> <Type>Wood</Type> <additionalElementsHere /> </Item> <Item label ="Category1Item2"> <Price>112.99</Price> <Type>Stone</Type> <additionalElementsHere /> </Item> <AdditionalItemsHere /></MenuItem><AdditionMenuITemsHere />\[/code\]I've been using a Telerik treeview bound to an XMLDataSource to display the data and allow users to interact with it (add/delete nodes, move nodes by means of drag and drop, or copy nodes and the underlying elements). So far, so good. Now my client would like to know if it is somehow possible to use the Element of the Item elements as grouping containers. So currently the treeview looks like this:\[code\]category1--Category1Item1--Category1Item2\[/code\]And ideally, it should end up looking like this:\[code\]category1--Wood----Category1Item1----Category1Item123--Stone----Category1Item2----Category1Item456\[/code\]I read up on HierarchicalDataTemnplates, but have not managed to figure out if these work in the ASP.NET controls supplied by Telerik. I would like to try and stick to what I have so far, as many hours of work have already gone into the product so far.I'd appreciate it if someone could point me in the right direction of how to tackle this particular issue.Thanks in advance :)Peter
 
Back
Top