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

how to bind grid directly from the xml datasource?

2 Answers 290 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Abid
Top achievements
Rank 1
Abid asked on 28 Jul 2011, 11:44 AM
I want to bind Grid directly from the datasource.. how do i do that? my code is :


<asp:XmlDataSource ID="XmlDataSource1" runat="server" EnableCaching="False" DataFile="~/Bin/xml.xml"
                                TransformFile="~/Bin/xml.xsl"></asp:XmlDataSource>

<telerik:RadGrid ID="RadGrid1" runat="server">
                                <HeaderContextMenu DataTextField="id" DataValueField="id">
                                </HeaderContextMenu>
                                <HeaderContextMenu DataTextField="name" DataValueField="name">
                                </HeaderContextMenu>
                                <HeaderContextMenu DataTextField="color" DataValueField="color">
                                </HeaderContextMenu>
                            </telerik:RadGrid>

2 Answers, 1 is accepted

Sort by
0
Abid
Top achievements
Rank 1
answered on 28 Jul 2011, 11:46 AM
ACCOMPLISHED!!!!! :D
0
Shinu
Top achievements
Rank 2
answered on 28 Jul 2011, 11:57 AM
Hello Abid,

You can try the same approach in the following demo.
Grid / Editing XML Using XmlDataSource.

Thanks,
Shinu.
Tags
Grid
Asked by
Abid
Top achievements
Rank 1
Answers by
Abid
Top achievements
Rank 1
Shinu
Top achievements
Rank 2
Share this question
or