Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

retrieving child nodes like an associative array

Status
Not open for further replies.

crazyboybert

Programmer
Jun 27, 2001
798
GB
I am looking for an XML method/property which can be used to gain access to a childNode of an element using the tagname similar to how an associative array works. The example below would loop through all child nodes of the root element looking for the text value of a child node with the tag name 'number'.

e.g. (ASP Code) objRootElement.childNodes(i).childNodes("number").text

There are properties such as firstchild which retrieve a specific node but i can find nothing other than getElementsByTagName which is document level scope not specific to an element. Or am I misunderstanding that?

Thanks in advance for any help

Rob ------------------------------------

Go placidly amidst the noise and haste,
find what peace there may be in silence.
-Anon

------------------------------------
 
Thanks James exactly what I was looking for and it was there amongst the maze of msdn all along...

[thumbsup] ------------------------------------

Go placidly amidst the noise and haste,
find what peace there may be in silence.
-Anon

------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top