Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries [Thread Prev] >Thread Next - One more thing... XPATH descendants repeatingTo: NULL Date: 7/3/2007 2:06:00 PM
I have a .NET 2.0 web form that has a Treeview control bound to an
XmlDataSource control bound to the following XML document (only the relevant
part of the document is shown here):
<TC1710 A="1" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="">
<TC5485 A="0" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="" />
<TC0191 A="0" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="">
<TC8133 A="0" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="">
<TC8151 A="1" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="" />
<TC1773 A="1" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="">
<TC1779 A="1" GQ="0" GQ1="0" GQ2="0" PS="0" GC="0" LC="0" OL="" />
</TC1773> />
</TC8133> />
</TC0191>
</TC1710>
I set the XPATH of the XmlDataSource to "//TC1710/descendant::*" with the
intention of selecting the descendant nodes of the TC1710 node expecting:
TC5485
-TC0191
--TC8133
---TC8151
---TC1773
----TC1779
But instead, each node that is within each descendant is displayed again as
separate branches:
TC5485
TC0191
-TC8133
--TC8151
--TC1773
---TC1779
TC8133
- TC8151
- TC1773
-- TC1779
TC8151
TC1773
- TC1779
TC1779
Shouldn't each node be displayed only once?
There are no duplicates in the XML document. I have not been able to
determine if this is an issue with my XPATH syntax, the XmlDataSource, or
the Treeview control.
I really need to be able to display the nodes as organized in the XML
document. This is my first XPATH project so any help will be greatly
appreciated.
David
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
