|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] XPath statement required pls
Hi,
I have XML file as follows:
<parameter name = "one">
<level1>
<level2 name = "a">
<level3>
<theField>something</theField>
</level3>
</level2>
<level2 name = "b">
<level3>
<theField>something</theField>
</level3>
</level2>
<level2 name = "c">
<level3>
<theField>something</theField>
</level3>
</level2>
</level1>
</parameter>
<parameter name = "two">
</parameter>
My problem is as follows:
1. I need to get all the occurrances of <theField> (... and that is fine, I
am getting those, using XPathAPI, into a NodeIterator)
2. For each field I want to get the nearest Attribute value, so that I can
uniquely identify <theField>. Is there a generic way to get the
nearest Attribute value? In my case it is not always true that the
attribute for a field (in this case <theField>) is at a particular level
(in the current case, I can get the attribute value by going w levels
up, ... but then that is what I am trying to find if there is generic
way to find the nearest Attribute value for a particular field)
Thanks in advance,
Sanjay
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








