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

XML Datasource with Treeview COntrol

4 Answers 173 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Hari
Top achievements
Rank 1
Hari asked on 07 Dec 2012, 04:50 PM
Hi,
We are trying to load a Kendo Tree view control with XML document as datasource. But we can't fnd any code samples for the same. We are struck here. Can anyone help us by providing some sampe code?

4 Answers, 1 is accepted

Sort by
0
Petur Subev
Telerik team
answered on 11 Dec 2012, 04:42 PM
Hello Hari,

Here is an example which shows how to bind the dataSource to XML:

http://demos.kendoui.com/web/datasource/xml-data.html

Once you create such dataSource it is few more lines to bind it to a TreeView, Grid, ListView or another widget.

Kind Regards,
Petur Subev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Hari
Top achievements
Rank 1
answered on 11 Dec 2012, 07:00 PM
Thanks for your response. I saw that code sample you have referred. But we are using ASP.NET MVC 3 for our project. Can we do the same code with ASP.NET MVC as well? If Yes can you please post some MVC code samples with XML Datasource?
0
Petur Subev
Telerik team
answered on 12 Dec 2012, 01:31 PM
Hello Hari,

Binding the dataSource to XML is supported only with the pure JavaScript web framework - you cannot configure the TreeView MVC Wrapper to use XML dataSource.

Regards,
Petur Subev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Hari
Top achievements
Rank 1
answered on 12 Dec 2012, 05:18 PM
Here is my sample XML:

<Name>
    <vehicles>
        <car>FM-1100</car>
        <car>FM-4200</car>
        <bike>FM-3100</bike>
    </vehicles>
    <personnel>
        <client>GH-3000</client>
        <vip>GH-3100</vip>
    </personnel>
</Name>


Can you please post some sample code to bind this with the Kendo treeview control using  JavaScript web framework ? All the exambles for binding XML are with grid not with tree view control.
Tags
General Discussions
Asked by
Hari
Top achievements
Rank 1
Answers by
Petur Subev
Telerik team
Hari
Top achievements
Rank 1
Share this question
or