Hi
I am trying to check if a node exists in an XML file before i output the value of one of it's attributes.
I am using ASP. (unfortunately)
I have tried using isNull but it always returns true using the MS dom.
If i use selectNodes with an XQL query and then looking at the length value of the object returned, it causes my existing code to break because i am looping through all the elements of a certain name within my domdoc.
Isnt there a simple method for checking an element exists and if not why not surely it should be part of the specification (for error checking if nothing else).
Thanks
Jez
I am trying to check if a node exists in an XML file before i output the value of one of it's attributes.
I am using ASP. (unfortunately)
I have tried using isNull but it always returns true using the MS dom.
If i use selectNodes with an XQL query and then looking at the length value of the object returned, it causes my existing code to break because i am looping through all the elements of a certain name within my domdoc.
Isnt there a simple method for checking an element exists and if not why not surely it should be part of the specification (for error checking if nothing else).
Thanks
Jez