Treeview xml format??

A

Alex D.

CAn anybody tell me which of the following is the correct XML format for
treview databinding? I need to be able to use many attributes like CHECKED
and EXPANDED. Tanks!

FORMAT #1

<TREENODES>
<treenode Text="Books" ID="1" Category="Fiction">
<treenode Text="Look Into Future" ID="1"/>
<treenode Text="What Tomorrow would be?" ID="1"/>
<treenode Text="Books" ID="1"/>
</treenode>
<treenode Text="Books" ID="2" Category="History">
<treenode Text="American History" ID="1"/>
<treenode Text="Indian History" ID="1"/>
<treenode Text="Japanese History" ID="1"/>
<treenode Text="UK History" ID="1"/>
</treenode>
<treenode Text="Books" ID="3" Category="Cartoon">
<treenode Text="Tom and Jerry" ID="1"/>
<treenode Text="Mickey Mouse" ID="1"/>
<treenode Text="Donald Duck" ID="1"/>
</treenode>
<treenode Text="Books" ID="4" Category="Mystery">
<treenode Text="Da Vinci Code" ID="1"/>
<treenode Text="The Wheels" ID="1"/>
<treenode Text="Chasing a Crooked Shadow" ID="1"/>
</treenode>
</TREENODES>

FORMAT #2

<?xml version='1.0'?>
<!-- This file represents a fragment of Product
store inventory database -->
<Products>
<Product ID="1" Name="Chai"
Price="13">
<Desc Value="10 boxes x 20 Bags"/>
</Product>
<Product ID="2" Name="Chang"
Price="10">
<Desc Value="24 -12 oz bottles"/>
</Product>
<Product ID="3" Name="Tofu"
Price="23.25">
<Desc Value="40-100 kg pkgs"/>
</Product>
</Products>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top