|
|
 |
FN-FORUM: ASP XML question
date posted 1st June 2005 17:31
I'm trying to parse some XML with ASP (classic, not .Net)... it's almost
all cracked except I need to get at an attribute of a node that may or
may not be there, and I need to find a way of checking whether it's
there before I try and get the data out of it, otherwise I get an error.
So...
The bit of XML might look like this:
Or it might be missing the 'C' node all together.
Normally I use objXML.getElementsByTagName("C") then
xmlAttribsNode.getAttribute("SZ") the thing is, if SZ is missing, it
throws an error. So, how do I check if "SZ" exists before I try and get
at it?
If I manage to find the answer through Google I'll post it up, but at
the moment I can't find anything useful.
Thanks
Paul
--
Paul Silver - Web Development and Technical Search Engine Optimisation
07813 654285 -- http://www.paulsilver.co.uk
Check your web pages: http://www.spidertest.com
|
 |
|